chainbridge-solidity icon indicating copy to clipboard operation
chainbridge-solidity copied to clipboard

Scoping

Open mrwillis opened this issue 2 years ago • 2 comments

We've made two changes to the handlers to support a 1 way bridge from source chain to destination chain. The first change is changing the way tokens are burnt on the source side. We create a new method manualBurnERC20 which will send tokens to the 0x000000000000000000000000dEAd address to support burning of tokens that don't have burnFrom.

Second change is supporting native asset redemptions on the dest side. We have a custom vault contract that ERC20SxHandler uses to pull assets from. We use a custom resourceId 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF to denote that we want different logic on the dest side instead of the standard ERC20Handler mint logic.

Final change unrelated to above is adding a few more events to aid in integration with front-ends.

mrwillis avatar Feb 28 '22 16:02 mrwillis

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.
0 out of 2 committers have signed the CLA.

:x: dankostiuk
:x: akshar
You have signed the CLA already but the status is still pending? Let us recheck it.

CLAassistant avatar Feb 28 '22 16:02 CLAassistant

ERC20SxHandler is deployed on the SX Network side. It is copied from ERC20Handler verbatim except in executeProposal. ERC20Handler is deployed on the source chain side.

mrwillis avatar Feb 28 '22 16:02 mrwillis