--- title: 'Ethereum' author: 'Hun Im' date: 2024-09-11T17:30:13+09:00 category: ['POSTS'] tags: ['Blockchain', 'Ethereum'] og_image: "/images/gamer.png" keywords: ['Blockchain', 'Ethereum'] --- ### What is Ethereum? 1. A blockchain-based platform used to run smart contracts and decentralized applications (dApps). 2. It offers various features beyond cryptocurrency transactions, including smart contract functionality. 3. The Ethereum network consists of numerous nodes, each responsible for maintaining and validating the Ethereum blockchain. **Ethereum Virtual Machine (EVM)** 1. A virtualized computing environment that runs smart contracts within the Ethereum network. 2. The core component of smart contracts and decentralized applications. 3. Acts as a virtual computer that operates in a decentralized manner on the Ethereum network. 4. Smart contracts are written in the Solidity language, compiled into bytecode, and executed by the EVM. **ERC** ERC (Ethereum Request for Comments) is a process used to propose and define standards for smart contracts on the Ethereum blockchain. 1. ERC-20: * Description: The most widely used token standard, used to create fungible tokens on the Ethereum blockchain. ERC-20 tokens have the same value and properties, with each unit treated equally. * Use Cases: Tokens used in ICOs (Initial Coin Offerings), utility tokens for various projects. * Functions: Defines basic token transfer and approval functions such as `transfer`, `approve`, and `transferFrom`. 2. ERC-721: * Description: The standard for **non-fungible tokens (NFTs)**, where each token has unique properties and cannot be exchanged one-to-one with other tokens. * Use Cases: Represents ownership of digital assets (e.g., CryptoKitties), art, and in-game items. * Functions: Tracks and transfers ownership of specific tokens using functions like `ownerOf` and `transferFrom`. 3. ERC-1155: * Description: A multi-token standard that allows for the management of both fungible and non-fungible tokens within a single contract. * Use Cases: Useful in games where various types of items (both regular and unique) need to be managed. * Functions: Efficiently transfers and manages multiple types of tokens using functions like `safeTransferFrom` and `balanceOf`. 4. ERC-777: * Description: An improved token standard over ERC-20, offering a more flexible transfer mechanism and enhanced security features. It allows the use of custom hooks during token transfers. * Use Cases: Used to overcome limitations of ERC-20 and in more complex smart contract systems. 5. ERC-1400: * Description: A standard for security tokens, providing stricter control over token ownership to meet legal requirements. * Use Cases: Security tokens (STOs), financial assets where regulatory compliance is essential.
Β
--- title: 'Ethereum' author: 'μν' date: 2024-09-11T17:30:13+09:00 category: ['POSTS'] tags: ['Blockchain', 'Ethereum'] og_image: "/images/gamer.png" keywords: ['Blockchain', 'Ethereum'] --- ### μ΄λ리μμ΄λ? 1. λΈλ‘μ²΄μΈ κΈ°λ° νλ«νΌ: μ€λ§νΈ κ³μ½κ³Ό νμ€μν μ ν리μΌμ΄μ (dApps) μ€ννλλ° μ¬μ© λλ€. 2. μνΈνν κ±°λ μ΄μμ λ€μν κΈ°λ₯(μ€λ§νΈκ³μ½ ν¨μ)μ μ 곡νλ€ 3. μ΄λ리μ λ€νΈμν¬λ μλ§μ λ Έλλ‘ κ΅¬μ±λμ΄ μμΌλ©°, κ° λ Έλλ μ΄λ리μ λΈλ‘체μΈμ μ μ§νκ³ κ²μ¦νλ μν μ νλ€. **μ΄λ리μ κ°μ λ¨Έμ (EVM, Ethereum Virtual Machine)** 1. μ΄λ리μ λ€νΈμν¬ λ΄μμ μ€λ§νΈ κ³μ½μ μ€ννλ κ°μνλ μ»΄ν¨ν νκ²½ 2. μ€λ§νΈ κ³μ½κ³Ό νμ€μν μ ν리μΌμ΄μ μ ν΅μ¬μμ 3. κ°μνλ μ»΄ν¨ν°λ‘, μ΄λ리μ λ€νΈμν¬μμ λΆμ°μ μΌλ‘ μ€ν 4. μ€λ§νΈ κ³μ½μ Solidity μΈμ΄λ‘, λ°μ΄νΈμ½λλ‘ μ»΄νμΌλμ΄, EVMμμ μ΄ λ°μ΄νΈμ½λλ₯Ό μ½μ΄ μ€ννλ€. **ERC** μ΄λ리μ λΈλ‘체μΈμμ μ€λ§νΈ κ³μ½ νμ€μ μ μνκ³ μ μνλ νλ‘μΈμ€μ΄λ€. 1. ERC-20: * μ€λͺ : κ°μ₯ λ리 μ¬μ©λλ ν ν° νμ€μΌλ‘, μ΄λ리μ λΈλ‘체μΈμμ **λ체 κ°λ₯ν ν ν°(fungible token)**μ μμ±νλ νμ€μ λλ€. ERC-20 ν ν°μ λμΌν κ°κ³Ό μμ±μ κ°μ§λ©°, λͺ¨λ λ¨μκ° λλ±νκ² μ·¨κΈλ©λλ€. * μ¬μ© μμ: λλΆλΆμ ICO(Initial Coin Offering)μμ μ¬μ©λ ν ν°, λ€μν νλ‘μ νΈμ μ νΈλ¦¬ν° ν ν° λ±. * κΈ°λ₯: `transfer`, `approve`, `transferFrom` λ±μ κΈ°λ³Έμ μΈ ν ν° μ μ‘ λ° μΉμΈ κΈ°λ₯μ μ μ. 2. ERC-721: * μ€λͺ : **λ체 λΆκ°λ₯ν ν ν°(NFT, Non-Fungible Token)** νμ€μΌλ‘, κ° ν ν°μ΄ κ³ μ ν μμ±μ κ°μ§λ©°, λ€λ₯Έ ν ν°κ³Ό λλ±νκ² κ΅νλμ§ μμ΅λλ€. * μ¬μ© μμ: λμ§νΈ μμ°(μ: CryptoKitties), μμ ν, κ²μ μμ΄ν λ±μ μμ κΆμ λνλ΄λ ν ν°. * κΈ°λ₯: `ownerOf`, `transferFrom` λ±μ ν΅ν΄ νΉμ ν ν°μ μμ κΆμ μΆμ νκ³ μ μ‘. 3. ERC-1155: * μ€λͺ : λ€μ€ ν ν° νμ€μΌλ‘, νλμ κ³μ½μμ λ체 κ°λ₯ν ν ν°κ³Ό λ체 λΆκ°λ₯ν ν ν°μ λμμ κ΄λ¦¬ν μ μμ΅λλ€. * μ¬μ© μμ: κ²μμμ λ€μν μ νμ μμ΄ν (μΌλ° μμ΄ν κ³Ό κ³ μ μμ΄ν )μ κ΄λ¦¬ν λ μ μ©. * κΈ°λ₯: `safeTransferFrom`, `balanceOf` λ±μ μ¬μ©ν΄ μ¬λ¬ μ νμ ν ν°μ ν¨μ¨μ μΌλ‘ μ μ‘ λ° κ΄λ¦¬. 4. ERC-777: * μ€λͺ : ERC-20μ κ°μ λ ν ν° νμ€μΌλ‘, λ μ μ°ν μ μ‘ λ©μ»€λμ¦κ³Ό 보μ κΈ°λ₯μ μ 곡ν©λλ€. νΉν, ν ν° μ μ‘ μ μ¬μ©μ μ μλ νν¬(hook) κΈ°λ₯μ μ¬μ©ν μ μμ΅λλ€. * μ¬μ© μμ: ERC-20μ νκ³λ₯Ό 극볡νκ³ λ 볡μ‘ν μ€λ§νΈ κ³μ½ μμ€ν μμ μ¬μ©. 5. ERC-1400: * μ€λͺ : 보μ ν ν°μ μν νμ€μΌλ‘, λ²μ μꡬμ¬νμ μΆ©μ‘±μν€κΈ° μν΄ ν ν° μμ κΆμ λμ± μ격νκ² κ΄λ¦¬νλ κΈ°λ₯μ μ 곡ν©λλ€. * μ¬μ© μμ: μ¦κΆν ν ν°(보μ ν ν°), κ·μ μκ±΄μ΄ μ€μν κΈμ΅ μμ°.