Ethereum Blockchain

Smart Contract

Solidity

亂數

由於區塊高度、timestamp 等不算是真正隨機亂數,可以加上 sender address 並 hash 過來增加亂度

Struct
struct Kitty {
    uint256 genes;
    uint64 birthTime;
    uint16 generation;
}
Modifier
modifier onlyOwner {
    require (msg.sender == owner);
    _;
}

Samples

Multi-Signature Wallet

Vyper

New experimental programming language

EIPs

ERC20 Token Standard

ERC165

ERC223 token standard

If the receiver is a contract, ERC223 token contract will try to call tokenFallback function on receiver contract. If there is no tokenFallback function on receiver contract transaction will fail.

會造成 false positive 的結果而未被採用。

Istanbul Byzantine Fault Tolerance #650

ERC677

Non-fungible Token Standard #721

ERC777

ERC865: Pay transfers in tokens instead of gas, in one transaction

Ability for token holders to pay transfer transactions in tokens instead of gas, in one transaction.

ERC875 for non fungible tokens and simple atomic swaps

ERC: Crypto Item Standard #1155

A standard interface for multiple item/token definitions in a single deployed contract.

Some White Papers

Decentralized Autonomous Organization (DAO)

Dapp

HD Wallet

一組主私鑰建立許多子私鑰,透過一份seed產生多組子私鑰,轉移錢包時只需要主私鑰。

Mnemonic code

列出錢包助記詞及產生規則。

Geth

  • Geth 基礎用法及架設 Muti-Nodes 私有鏈
  • 操作 macOS 的 Mist App 內的 Geth ~/Library/Application\ Support/Mist/binaries/Geth/unpacked/geth attach ~/Library/Ethereum/geth.ipc -> net.peerCount 可以顯示目前連接的 peer 數量
  • Infura - Your Access to the Ethereum Network
    • 除了自己用 geth 架一個以太坊節點,也可以用其他人的節點來測試或遞送交易

Other

Wallet

DAICO: DAO + ICO

DAICO

Parity

Ethereum Name System

Casper The Friendly Finality Gadget

Proof of stake on Ethereum.

https://vitalik.ca/files/casper_note.html

https://github.com/ethereum/research/blob/master/papers/casper-basics/casper_basics.pdf

https://github.com/ethereum/casper

Ether Cards

提供一組錢包,但預設私鑰是隱藏起來的,送禮的人可以放錢進去後,將卡片送人,收禮的人可以刮開私鑰然後將裡面的虛擬貨幣提領出來。