Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add process of verifying TeleporterMessenger #669

Merged
merged 4 commits into from
Dec 4, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 20 additions & 1 deletion contracts/teleporter/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
- [Upgradability](#upgradability)
- [Deploy TeleporterMessenger to an L1](#deploy-teleportermessenger-to-an-avalanche-l1)
- [Deploy TeleporterRegistry to an L1](#deploy-teleporterregistry-to-an-avalanche-l1)
- [Verify a Deployment of TeleporterMessenger](#verify-a-deployment-of-teleporterMessenger)

## Overview

Expand Down Expand Up @@ -173,4 +174,22 @@ Required arguments:
- `--rpc-url <url>` Specify the rpc url of the node to use.
- `--private-key <private_key>` Funds the deployer address with the account held by `<private_key>`

`deploy_registry.sh` will deploy a new `TeleporterRegistry` contract for the intended release version, and will also have the corresponding `TeleporterMessenger` contract registered as the initial protocol version.
`deploy_registry.sh` will deploy a new `TeleporterRegistry` contract for the intended release version, and will also have the corresponding `TeleporterMessenger` contract registered as the initial protocol version.

## Verify a Deployment of TeleporterMessenger

`TeleporterMessenger` can be verified on L1s using sourcify. `v1.0.0` of this repository must be checked out in order to match the source code properly.

```bash
git checkout v1.0.0
git submodule update --init --recursive
cd contracts

forge verify-contract 0x253b2784c75e510dD0fF1da844684a1aC0aa5fcf \
src/teleporter/TeleporterMessenger.sol:TeleporterMessenger \

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should this be <YOUR_CHAIN_ID>?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why yes, thank you stranger 👀

--chain-id 13337 \
--rpc-url <YOUR_RPC_URL> \
--verifier sourcify \
--compiler-version v0.8.18+commit.87f61d96 \
geoff-vball marked this conversation as resolved.
Show resolved Hide resolved
--num-of-optimizations 200 \
```
Loading