This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # wiki page | |
| https://en.bitcoin.it/wiki/Contract | |
| # Nick Szabo essays | |
| http://szabo.best.vwh.net/smart_contracts_idea.html | |
| http://szabo.best.vwh.net/smart.contracts.html | |
| http://szabo.best.vwh.net/micropayments.html | |
| # secure multiparty computation in bitcoin | |
| https://eprint.iacr.org/2013/784.pdf |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| OP_0 | |
| OP_<M> | |
| <pubkey1> <pubkey2> ... <pubkeyN> | |
| OP_<N> | |
| OP_CHECKMULTISIG |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| OP_DUP | |
| OP_HASH160 | |
| <hash(publicKey)> | |
| OP_EQUALVERIFY OP_CHECKSIG |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| OP_IF | |
| <expiry time> OP_CHECKLOCKTIMEVERIFY OP_DROP | |
| <consumer pubkey> OP_CHECKSIG | |
| OP_ELSE | |
| OP_0 2 <consumer pubkey> <provider pubkey> 2 OP_CHECKMULTISIG | |
| OP_END |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| 0: 'tench, Tinca tinca', | |
| 1: 'goldfish, Carassius auratus', | |
| 2: 'great white shark, white shark, man-eater, man-eating shark, Carcharodon carcharias', | |
| 3: 'tiger shark, Galeocerdo cuvieri', | |
| 4: 'hammerhead, hammerhead shark', | |
| 5: 'electric ray, crampfish, numbfish, torpedo', | |
| 6: 'stingray', | |
| 7: 'cock', | |
| 8: 'hen', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var clientID = "oC8AfNfY3JTOV5PIFkqKbIgLgzFqc0By"; | |
| var domain = "bitcorps.auth0.com"; | |
| var full = location.protocol+'//'+location.hostname+(location.port ? ':'+location.port: ''); | |
| var dict = { | |
| title: "BitCorps", | |
| } | |
| var options = { | |
| "responseType":"token", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| geth --testnet --rpc console 2>> geth.log |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| > personal.newAccount() | |
| Passphrase: | |
| Repeat passphrase: | |
| "0xa88614166227d83c93f4c50be37150b9500d51fc" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| > eth.getBalance(eth.accounts[0]) | |
| 0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # First, let's install truffle | |
| $ sudo npm install -g truffle | |
| # let's setup our project | |
| $ mkdir solidity-experiments | |
| $ cd solidity-experiments/ | |
| $ truffle init | |
| $ ls | |
| app contracts migrations test truffle.js |