Ethereum Concepts
- definition
- blocks
- the state
- nodes communications
- miners
- validity
- consensus
- Ether (ETH)
- ETH & Ethereum
- user accounts
- contracts
- addresses
- EVM (Ethereum Virtual Machine)
- Gas
↓
- definition
- blocks
- the state
- nodes communications
- miners
- validity
- consensus
- Ether (ETH)
- ETH & Ethereum
- user accounts
- contracts
- addresses
- EVM (Ethereum Virtual Machine)
- Gas
↓
Ethereum definition
Is a network of computers, called nodes.
Ethereum is a permissionless and non-hierarchical network.
Ethereum builds and comes to a consensus on an ever-growing series of BLOCKS, known as the blockchain.
Is a network of computers, called nodes.
Ethereum is a permissionless and non-hierarchical network.
Ethereum builds and comes to a consensus on an ever-growing series of BLOCKS, known as the blockchain.
Blocks
Each block contains an identifier of the chain. It must precede it if the block is to be considered valid.
When a node adds a block to its chain, it executes the transactions therein in their order, altering the ETH balances and other storage values of Ethereum accounts.
Each block contains an identifier of the chain. It must precede it if the block is to be considered valid.
When a node adds a block to its chain, it executes the transactions therein in their order, altering the ETH balances and other storage values of Ethereum accounts.
The state
The balances and values, collectively known as THE STATE, are maintained in a Merkle tree on the node's computer, separated from the blockchain.
The balances and values, collectively known as THE STATE, are maintained in a Merkle tree on the node's computer, separated from the blockchain.
Nodes communication and propagation
Each node communicates with a small subset of the network, known as its peers.
When a node wishes to include a new transaction in the blockchain, it sends the transaction to its peers, who then send it to their peers, and so on.
Each node communicates with a small subset of the network, known as its peers.
When a node wishes to include a new transaction in the blockchain, it sends the transaction to its peers, who then send it to their peers, and so on.
Miners
Miners are nodes that maintain a list of all of these new transactions and use them to create new blocks, which they then send to the rest of the network.
Miners are nodes that maintain a list of all of these new transactions and use them to create new blocks, which they then send to the rest of the network.
Validity
When a node receives a block, it checks the validity of the block and of all of the transactions.
If valid, the node adds the block and transactions to the blockchain.
Being the network non-hierarchical, it may receive competing blocks, which may form competing chains
When a node receives a block, it checks the validity of the block and of all of the transactions.
If valid, the node adds the block and transactions to the blockchain.
Being the network non-hierarchical, it may receive competing blocks, which may form competing chains
Consensus
"The chain with the most blocks at any given time is the canonical chain".
This is called the LONGEST-CHAIN rule.
This rule achieves consensus: miners don't want to expend their computational work trying to add blocks to a chain that will be abandoned by the network.
"The chain with the most blocks at any given time is the canonical chain".
This is called the LONGEST-CHAIN rule.
This rule achieves consensus: miners don't want to expend their computational work trying to add blocks to a chain that will be abandoned by the network.
Ether (ETH)
Ether (ETH) is the cryptocurrency generated by the Ethereum protocol as a reward to miners in a proof-of-work system for adding blocks to the blockchain.
It's the only currency accepted in the payment of transaction fees, which also go to miners.
Ether (ETH) is the cryptocurrency generated by the Ethereum protocol as a reward to miners in a proof-of-work system for adding blocks to the blockchain.
It's the only currency accepted in the payment of transaction fees, which also go to miners.
ETH & Ethereum
The block reward together with the transaction fees provides the incentive to miners to keep the blockchain growing.
Therefore, ETH is fundamental to the operation of the network.
Each Ethereum account has an ETH balance and may send ETH to any other account.
The block reward together with the transaction fees provides the incentive to miners to keep the blockchain growing.
Therefore, ETH is fundamental to the operation of the network.
Each Ethereum account has an ETH balance and may send ETH to any other account.
Accounts
Two types of accounts on Ethereum:
- user accounts
- contracts
Both types:
- have an ETH balance
- may send ETH to any account
- may call a public function of a contract
- may create a new contract
They're identified on the blockchain and in the state by the address
Two types of accounts on Ethereum:
- user accounts
- contracts
Both types:
- have an ETH balance
- may send ETH to any account
- may call a public function of a contract
- may create a new contract
They're identified on the blockchain and in the state by the address
User accounts
The only type that may create transactions.
For a transaction to be valid, it must be signed using the sending account's private key.
The algorithm used for the signature is ECDSA. It allows deriving the signer's address from the signature without the private key
The only type that may create transactions.
For a transaction to be valid, it must be signed using the sending account's private key.
The algorithm used for the signature is ECDSA. It allows deriving the signer's address from the signature without the private key
Contracts
The only account which has associated:
- code: set of functions/ variable declarations
- contract storage: variables' values at any given time
A contract function may take arguments and may have return values.
The only account which has associated:
- code: set of functions/ variable declarations
- contract storage: variables' values at any given time
A contract function may take arguments and may have return values.
A Contract can:
- control flow statements
- include instructions to send ETH
- perform I/O ops
- create temp storage
- perform arithmetic/hashing ops
- call its own functions
- call contracts' public functions
- create new contracts
- query info about transaction/blockchain.
- control flow statements
- include instructions to send ETH
- perform I/O ops
- create temp storage
- perform arithmetic/hashing ops
- call its own functions
- call contracts' public functions
- create new contracts
- query info about transaction/blockchain.
Addresses
Ethereum addresses are composed of:
"0x" + the rightmost 20 bytes of the Keccak-256 hash of the ECDSA public key.
Contract addresses are in the same format, but they are determined by sender and creation transaction nonce.
Ethereum addresses are composed of:
"0x" + the rightmost 20 bytes of the Keccak-256 hash of the ECDSA public key.
Contract addresses are in the same format, but they are determined by sender and creation transaction nonce.
EVM
It's the runtime environment for transaction execution in Ethereum.
It's a 256-bit register stack, sandboxed from the node's other files.
It ensures that for a given pre-transaction state and transaction, every node produces the same post-transaction state.
It's the runtime environment for transaction execution in Ethereum.
It's a 256-bit register stack, sandboxed from the node's other files.
It ensures that for a given pre-transaction state and transaction, every node produces the same post-transaction state.
Etereum Virtual Machine implementation:
EVMs have been implemented in many different languages:
- C++
- C#
- Go
- Haskell
- Java
- JavaScript
- Python
- Ruby
- Rust
- Elixir
- Erlang
More programming languages can be added in the future.
EVMs have been implemented in many different languages:
- C++
- C#
- Go
- Haskell
- Java
- JavaScript
- Python
- Ruby
- Rust
- Elixir
- Erlang
More programming languages can be added in the future.
Gas
Gas is a unit of account within the EVM used in the calculation of a transaction fee. It is the amount of ETH a transaction's sender must pay to the miner who includes the transaction in the blockchain.
Source: Wikipedia
Gas is a unit of account within the EVM used in the calculation of a transaction fee. It is the amount of ETH a transaction's sender must pay to the miner who includes the transaction in the blockchain.
Source: Wikipedia
If you liked this Thread, follow @FrancescoCiull4 and share this:
Loading suggestions...