Skip to content

Adding Near -> Eth connectors#99

Merged
sept-en merged 71 commits into
Near-One:masterfrom
ilblackdragon:near-eth-connectors
Aug 10, 2022
Merged

Adding Near -> Eth connectors#99
sept-en merged 71 commits into
Near-One:masterfrom
ilblackdragon:near-eth-connectors

Conversation

@ilblackdragon

Copy link
Copy Markdown
Contributor

Two new connectors are added:

  • token-factory - locks NEP141 tokens on NEAR side and emits <token, amount, recipient address>. Accepts Unlock event from Ethereum side, verifies it's correctness and releases funds to it.
  • erc20-bridge-token - BridgeTokenFactory and BridgeToken Ethereum contracts. BridgeTokenFactory creates new BridgeToken that correspond to specific token account id on NEAR side. BridgeTokenFactory can receive events from NEAR, verify them and mint appropriate amounts on recipient addresses. Calling withdraw will burn tokens of this user and will generate event <> that can be relayed to token-factory.

@ilblackdragon ilblackdragon requested a review from sept-en as a code owner March 27, 2022 14:53
@sept-en sept-en self-assigned this Mar 28, 2022
@sept-en sept-en added enhancement New feature or request security labels Mar 28, 2022

@sept-en sept-en left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks for implementing such useful things, guys!

Added some comments that need to be addressed as per the initial review. In general, looks good!

Comment thread bridge-common/Cargo.toml Outdated
Comment thread bridge-common/Cargo.toml Outdated
Comment thread bridge-common/Cargo.toml Outdated
Comment thread bridge-common/src/lib.rs Outdated
Comment thread erc20-bridge-token/contracts/BridgeToken.sol Outdated
Comment thread token-locker/rust-toolchain Outdated
Comment thread token-locker/src/lib.rs
Comment thread token-locker/src/lib.rs
Comment thread README.md
Comment thread README.md
Co-authored-by: Kirill <gammerxpower@gmail.com>
@ilblackdragon

ilblackdragon commented Apr 1, 2022

Copy link
Copy Markdown
Contributor Author

I didn't update to near-plugins because versions of dependencies don't match.
To actually do this, everything including near-plugins and rainbow needs to be updated to the new versions properly.

I suggest to do that in a separate PR otherwise, this going to be a huge mess as it needs all changes from #96

@mfornet mfornet left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks good security wise.

Comment thread token-locker/src/lib.rs Outdated
Comment thread token-locker/src/lib.rs
Comment thread token-locker/src/lib.rs Outdated
Comment thread erc20-bridge-token/contracts/BridgeTokenFactory.sol Outdated
Comment thread erc20-bridge-token/contracts/BridgeToken.sol Outdated
Comment thread erc20-bridge-token/contracts/BridgeToken.sol Outdated
Comment thread erc20-bridge-token/contracts/BridgeToken.sol Outdated
@Shockedshodan

Copy link
Copy Markdown
Contributor

5a77538

Last update - I cut some errors just to get some space. Is it ok?

Shockedshodan and others added 2 commits June 3, 2022 12:08
Co-authored-by: Kirill <gammerxpower@gmail.com>
Co-authored-by: Kirill <gammerxpower@gmail.com>
@sept-en

sept-en commented Jun 3, 2022

Copy link
Copy Markdown
Contributor

5a77538

Last update - I cut some errors just to get some space. Is it ok?

No, please revert.

@Shockedshodan

Shockedshodan commented Jun 3, 2022

Copy link
Copy Markdown
Contributor

Reverted

ilblackdragon@aca89f0

@Shockedshodan Shockedshodan force-pushed the near-eth-connectors branch from e4b3ee6 to 2496b3f Compare June 3, 2022 11:59
@sept-en sept-en requested review from karim-en and sept-en June 20, 2022 12:27
@sept-en sept-en requested a review from mfornet August 8, 2022 14:48

@sept-en sept-en left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Merging it now. All future improvements should be done in separate PRs.

@sept-en sept-en merged commit f7f3fea into Near-One:master Aug 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request security

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants