You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Current implementation of the erc20-to-erc20 bridge mode assumes that pure ERC20 token is used on the Foreign side. So, when the tokens are relayed to the Home side, the method transfer is invoked by the user and the relay request is handled by the TokenBridge oracle without involvement the bridge contract on the Foreign side. It is inconvenient due to following:
there is no way to revert the request if it exceeds the limits.
there is no way to halt the bridge operations
Historically, such kind of functionality was suggested for already deployed ERC20 tokens to enhance them through the bridging ability and described shortcomings were considered as insignificant in comparison with the value such solution could bring. But for there are the cases for the bridge when it is going to be used with just deployed tokens. In this case the token could be extended by ERC677 standard in order to address issues described above.
In order to allow the Token Bridge monitor to discover the transfer issues with the bridge in the erc-to-erc mode its behavior should be extended to watch for UserRequestForAffirmation events on the Foreign Brdige contract. The approach to look for exact event and use a right contract for this could be identified by checking whether the ERC20 token contract has the bridgeContract method and it points to the same bridge contract the monitor must work with.
The text was updated successfully, but these errors were encountered:
Current implementation of the
erc20-to-erc20
bridge mode assumes that pure ERC20 token is used on the Foreign side. So, when the tokens are relayed to the Home side, the methodtransfer
is invoked by the user and the relay request is handled by the TokenBridge oracle without involvement the bridge contract on the Foreign side. It is inconvenient due to following:Historically, such kind of functionality was suggested for already deployed ERC20 tokens to enhance them through the bridging ability and described shortcomings were considered as insignificant in comparison with the value such solution could bring. But for there are the cases for the bridge when it is going to be used with just deployed tokens. In this case the token could be extended by ERC677 standard in order to address issues described above.
That's why the PR omni/tokenbridge-contracts#175 was created in the bridge contracts repo.
In order to allow the Token Bridge monitor to discover the transfer issues with the bridge in the
erc-to-erc
mode its behavior should be extended to watch forUserRequestForAffirmation
events on the Foreign Brdige contract. The approach to look for exact event and use a right contract for this could be identified by checking whether the ERC20 token contract has thebridgeContract
method and it points to the same bridge contract the monitor must work with.The text was updated successfully, but these errors were encountered: