Skip to content

Instantly share code, notes, and snippets.

@enu-kuro
Last active August 1, 2022 11:49
Show Gist options
  • Save enu-kuro/25017ad3eab4a59c19507270d2f61abc to your computer and use it in GitHub Desktop.
Save enu-kuro/25017ad3eab4a59c19507270d2f61abc to your computer and use it in GitHub Desktop.
Research on Aurora EVM

Concise explanation about Aurora Engine

Let’s start with a quick recap of what the Aurora Engine is and how it works. The Engine is a smart contract written in Rust on the NEAR blockchain. It contains a full EVM interpreter to be able to execute transactions exactly the same as Ethereum, as well as all the auxiliary logic for validating transactions before execution (checking signature, nonce, account balance vs gas price, etc).

When you send a transaction to an Aurora RPC endpoint our infrastructure wraps your signed Ethereum transaction into a NEAR transaction for the Engine. This means each Aurora transaction becomes a NEAR transaction, and therefore must follow the rules of the NEAR protocol.

https://aurora.dev/blog/aurora-engine-2-4-0-release

Near team tried introducing EVM runtime without any change in the current NEAR Protocol.
Aurora's EVM runtime is just a Near's smart contract.

Relayers wrap Ethereum transactions which Aurora users send into NEAR transactions so actualy all Aurora's transactions are also Near's transaciton.
Aurora users pay ETH(bridge from Ethereum) to relayers for EVM gas fee and relayers pay NEAR for Near's smart contract execution instead of Aurora users.

You can see Aurora smart contract's transactions on Near.
https://explorer.near.org/accounts/aurora

For normal Ethereum transaction, relayers call "submit" method in the Aurora smart contract.
https://github.com/aurora-is-near/aurora-engine/blob/7109e30926ea33f67c6f702aa2b796b025cca96a/engine/src/lib.rs#L244

Interesting Topics:

Questions:

  • Can you implement EVM written in Move?
    And is it's computation cost acceptable level?

- Are there no scaling problem on Aptos?
Near has a sharding so even if Aurora were congested it won't affect other shared and theoretically create multiple EVM runtimes in other shard.

  • Can Aptos excute transactions sequentially?
    Aptos seems to excute transactions in parallel but EVM needs sequential excution.
@enu-kuro
Copy link
Author

enu-kuro commented Jul 30, 2022

My impression of Neon EVM on Solana

Solana's parallel smart contracts runtime and the way of storing data don't go well with EVM...
Because of these features Neon EVM needs a lot of tweaks and becomes too complicated.
https://docs.neon-labs.org/docs/architecture/neon_evm_arch
https://neon-labs.org/Neon_EVM.pdf
https://docs.neon-labs.org/docs/faq/how-does-neon-work#why-do-transactions-go-through-the-neon-web3-proxy-before-the-neon-evm-by-default

@enu-kuro
Copy link
Author

Security

Near and Solana allow to upgrade smart contracts.
It means users have to trust EVM contract's owner.
I found Neon's governance explanation but not Aurora.
https://docs.neon-labs.org/docs/governance/governance_overview

EVM as smart contract looks not so secure like bridges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment