Go Usechain
Official golang implementation of the Usechain.
The source files are based on go-ethereum, thanks to Ethereum authors.
Many documents you can reference to go-ethereum.
Automated builds are available for stable releases and the unstable master branch.
Binary archives are published at https://github.com/usechain/go-usechain/releases .
Building the source
Building usechain requires both a Go (version 1.10 or later) and a C compiler.
You can install them using your favourite package manager.
Once the dependencies are installed, run
$ make used
or, to build the full suite of utilities:
$ make all
Identity Verification
To begin with, you need to upload your identity informations to acquire certificate from certificate authority.
Remember to store the key you received from CA after you upload the informations.
$ ./build/bin/used verify
$ ./build/bin/used verify --info=userData.json --photo="<yourphotopath1>;<yourphotopath2>"
After waiting serval hours when CA confirmed your informations and documents, you can download your certificate.
You will be noticed if you failed verification.
$ ./build/bin/used verify --query=<yourkey>
One more step, open your used console and send verification transaction.
> use.sendCreditRegisterTransaction({from:<yourethaddress>,to:"0xfffffffffffffffffffffffffffffffff0000001",gas:'0x332423'})
// 0xfffffffffffffffffffffffffffffffff0000001 is the address of CA verification smart contract
Pleas refer to 用户身份认证流程 for more details.
Programatically interfacing usechain nodes
As a developer, sooner rather than later you'll want to start interacting with usechain and the usechain
network via your own programs and not manually through the console. To aid this, usechain has built in
support for a JSON-RPC based APIs . These can be
exposed via HTTP, WebSockets and IPC (unix sockets on unix based platforms, and named pipes on Windows).
The IPC interface is enabled by default and exposes all the APIs supported by usechain, whereas the HTTP
and WS interfaces need to manually be enabled and only expose a subset of APIs due to security reasons.
These can be turned on/off and configured as you'd expect.
HTTP based JSON-RPC API options:
--rpc
Enable the HTTP-RPC server
--rpcaddr
HTTP-RPC server listening interface (default: "localhost")
--rpcport
HTTP-RPC server listening port (default: 8545)
--rpcapi
API's offered over the HTTP-RPC interface (default: "eth,net,web3")
--rpccorsdomain
Comma separated list of domains from which to accept cross origin requests (browser enforced)
--ws
Enable the WS-RPC server
--wsaddr
WS-RPC server listening interface (default: "localhost")
--wsport
WS-RPC server listening port (default: 8546)
--wsapi
API's offered over the WS-RPC interface (default: "eth,net,web3")
--wsorigins
Origins from which to accept websockets requests
--ipcdisable
Disable the IPC-RPC server
--ipcapi
API's offered over the IPC-RPC interface (default: "admin,debug,eth,miner,net,personal,shh,txpool,web3")
--ipcpath
Filename for IPC socket/pipe within the datadir (explicit paths escape it)
You'll need to use your own programming environments' capabilities (libraries, tools, etc) to connect
via HTTP, WS or IPC to a usechain node configured with the above flags and you'll need to speak JSON-RPC
on all transports. You can reuse the same connection for multiple requests!
Note: Please understand the security implications of opening up an HTTP/WS based transport before
doing so! Hackers on the internet are actively trying to subvert usechain nodes with exposed APIs!
Further, all browser tabs can access locally running webservers, so malicious webpages could try to
subvert locally available APIs!
Operating a private network
Maintaining your own private network is more involved as a lot of configurations taken for granted in
the official networks need to be manually set up.
Defining the private genesis state
First, you'll need to create the genesis state of your networks, which all nodes need to be aware of
and agree upon. This consists of a JSON file (e.g. call it genesis.json
, you can find it in go-usechain/build/config/
):
{
"nonce":"0x0000000000000042",
"mixhash":"0x0000000000000000000000000000000000000000000000000000000000000000",
"difficulty": "0x4000",
"alloc": {
"0xfffffffffffffffffffffffffffffffff0000001": {
"balance": "1000000000000000000000000000",
"code": "0x6060604052600436106100e6576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff16806334443b9a146100eb578063412f12cd146101405780635c594f9d146102c35780636386c1c71461032d57806366f57632146104b1578063678eac36146105025780637df73e27146105bc578063a02b161e1461060d578063a98430f41461064c578063bb29998e1461069d578063c7aedd1f146106ee578063cd7de02e1461074c578063d6127c65146107ac578063e5c8b03d146107d5578063eb12d61e146107ea578063f8161f7514610823575b600080fd5b34156100f657600080fd5b6100fe610920565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b341561014b57600080fd5b610165600480803560001916906020019091905050610946565b6040518080602001806020018515151515815260200180602001848103845288818151815260200191508051906020019080838360005b838110156101b757808201518184015260208101905061019c565b50505050905090810190601f1680156101e45780820380516001836020036101000a031916815260200191505b50848103835287818151815260200191508051906020019080838360005b8381101561021d578082015181840152602081019050610202565b50505050905090810190601f16801561024a5780820380516001836020036101000a031916815260200191505b50848103825285818151815260200191508051906020019080838360005b83811015610283578082015181840152602081019050610268565b50505050905090810190601f1680156102b05780820380516001836020036101000a031916815260200191505b5097505050505050505060405180910390f35b34156102ce57600080fd5b6102d6610bc9565b6040518080602001828103825283818151815260200191508051906020019060200280838360005b838110156103195780820151818401526020810190506102fe565b505050509050019250505060405180910390f35b341561033857600080fd5b610364600480803573ffffffffffffffffffffffffffffffffffffffff16906020019091905050610c2b565b604051808673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020018060200185600019166000191681526020018060200180602001848103845288818151815260200191508051906020019080838360005b838110156103ec5780820151818401526020810190506103d1565b50505050905090810190601f1680156104195780820380516001836020036101000a031916815260200191505b50848103835286818151815260200191508051906020019060200280838360005b8381101561045557808201518184015260208101905061043a565b50505050905001848103825285818151815260200191508051906020019060200280838360005b8381101561049757808201518184015260208101905061047c565b505050509050019850505050505050505060405180910390f35b34156104bc57600080fd5b6104e8600480803573ffffffffffffffffffffffffffffffffffffffff16906020019091905050610f38565b604051808215151515815260200191505060405180910390f35b6105a260048080356000191690602001909190803590602001908201803590602001908080601f0160208091040260200160405190810160405280939291908181526020018383808284378201915050505050509190803590602001908201803590602001908080601f01602080910402602001604051908101604052809392919081815260200183838082843782019150505050505091905050610fb9565b604051808215151515815260200191505060405180910390f35b34156105c757600080fd5b6105f3600480803573ffffffffffffffffffffffffffffffffffffffff1690602001909190505061138a565b604051808215151515815260200191505060405180910390f35b341561061857600080fd5b61062e60048080359060200190919050506113a7565b60405180826000191660001916815260200191505060405180910390f35b341561065757600080fd5b610683600480803573ffffffffffffffffffffffffffffffffffffffff169060200190919050506113cb565b604051808215151515815260200191505060405180910390f35b34156106a857600080fd5b6106d4600480803573ffffffffffffffffffffffffffffffffffffffff169060200190919050506116be565b604051808215151515815260200191505060405180910390f35b34156106f957600080fd5b610732600480803573ffffffffffffffffffffffffffffffffffffffff16906020019091908035600019169060200190919050506117ae565b604051808215151515815260200191505060405180910390f35b341561075757600080fd5b610783600480803573ffffffffffffffffffffffffffffffffffffffff16906020019091905050611bb6565b604051808360001916600019168152602001821515151581526020019250505060405180910390f35b34156107b757600080fd5b6107bf611c51565b6040518082815260200191505060405180910390f35b34156107e057600080fd5b6107e8611c5e565b005b34156107f557600080fd5b610821600480803573ffffffffffffffffffffffffffffffffffffffff16906020019091905050611c69565b005b610906600480803590602001908201803590602001908080601f016020809104026020016040519081016040528093929190818152602001838380828437820191505050505050919080356000191690602001909190803590602001908201803590602001908080601f0160208091040260200160405190810160405280939291908181526020018383808284378201915050505050509190803590602001908201803590602001908080601f01602080910402602001604051908101604052809392919081815260200183838082843782019150505050505091905050611c89565b604051808215151515815260200191505060405180910390f35b600460009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b61094e612404565b610956612404565b6000610960612418565b61096861242c565b60026000876000191660001916815260200190815260200160002060a06040519081016040529081600082018054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610a285780601f106109fd57610100808354040283529160200191610a28565b820191906000526020600020905b815481529060010190602001808311610a0b57829003601f168201915b50505050508152602001600182018054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610aca5780601f10610a9f57610100808354040283529160200191610aca565b820191906000526020600020905b815481529060010190602001808311610aad57829003601f168201915b505050505081526020016002820160009054906101000a900460ff1615151515815260200160038201548152602001600482018054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610b915780601f10610b6657610100808354040283529160200191610b91565b820191906000526020600020905b815481529060010190602001808311610b7457829003601f168201915b505050505081525050905080600001518160200151826040015183608001518393508292508090509450945094509450509193509193565b610bd1612470565b6003805480602002602001604051908101604052809291908181526020018280548015610c2157602002820191906000526020600020905b81546000191681526020019060010190808311610c09575b5050505050905090565b6000610c35612418565b6000610c3f612470565b610c47612484565b600160008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16600160008873ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600101600160008973ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060020160000154600160008a73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600401600001600160008b73ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600401600101838054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610e515780601f10610e2657610100808354040283529160200191610e51565b820191906000526020600020905b815481529060010190602001808311610e3457829003601f168201915b5050505050935081805480602002602001604051908101604052809291908181526020018280548015610ea757602002820191906000526020600020905b81546000191681526020019060010190808311610e8f575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015610f1e57602002820191906000526020600020906000905b82829054906101000a900460ff16151581526020019060010190602082600001049283019260010382029150808411610ee85790505b505050505090509450945094509450945091939590929450565b60006001151560026000600160008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600201600001546000191660001916815260200190815260200160002060020160009054906101000a900460ff161515149050919050565b600080610fc461242c565b600073ffffffffffffffffffffffffffffffffffffffff16600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161415151561106257600080fd5b6001600380548060010182816110789190612498565b916000526020600020900160008990919091509060001916905503915060a060405190810160405280868152602001858152602001600015158152602001838152602001600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206001018054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156111925780601f1061116757610100808354040283529160200191611192565b820191906000526020600020905b81548152906001019060200180831161117557829003601f168201915b505050505081525090508060026000886000191660001916815260200190815260200160002060008201518160000190805190602001906111d49291906124c4565b5060208201518160010190805190602001906111f19291906124c4565b5060408201518160020160006101000a81548160ff021916908315150217905550606082015181600301556080820151816004019080519060200190611238929190612544565b50905050600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060040160000180548060010182816112939190612498565b916000526020600020900160008890919091509060001916905550600160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600401600101805480600101828161130591906125c4565b91600052602060002090602091828204019190066000909190916101000a81548160ff0219169083151502179055505085600019163373ffffffffffffffffffffffffffffffffffffffff167f3f8181daf25431ca282f53b53dcc2105734a2919eb1bbf9ea67d820db17ae70460405160405180910390a36001925050509392505050565b60006113a082600061215d90919063ffffffff16565b9050919050565b6003818154811015156113b657fe5b90600052602060002090016000915090505481565b60008060006113d93361138a565b15156113e457600080fd5b600073ffffffffffffffffffffffffffffffffffffffff16600160008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161415151561148257600080fd5b60018060008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060020160010160006101000a81548160ff021916908315150217905550600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600201600001549150600160026000846000191660001916815260200190815260200160002060020160006101000a81548160ff021916908315150217905550600090505b600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020600401600001805490508110156116b257600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206004016000018181548110151561160557fe5b90600052602060002090015460001916826000191614156116a55760018060008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206004016001018281548110151561167357fe5b90600052602060002090602091828204019190066101000a81548160ff021916908315150217905550600192506116b7565b8080600101915050611563565b600092505b5050919050565b600060011515600460009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663855a6e73846000604051602001526040518263ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050602060405180830381600087803b151561178957600080fd5b6102c65a03f1151561179a57600080fd5b505050604051805190501515149050919050565b6000803360011515600460009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663855a6e73836000604051602001526040518263ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050602060405180830381600087803b151561187b57600080fd5b6102c65a03f1151561188c57600080fd5b5050506040518051905015151415156118a457600080fd5b600073ffffffffffffffffffffffffffffffffffffffff16600160008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161415151561194257600080fd5b600160026000866000191660001916815260200190815260200160002060020160006101000a81548160ff021916908315150217905550600091505b600160008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060040160000180549050821015611ba957600160008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060040160000182815481101515611a2057fe5b9060005260206000209001546000191684600019161415611b9c5760018060008773ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060040160010183815481101515611a8e57fe5b90600052602060002090602091828204019190066101000a81548160ff0219169083151502179055506003600160038054905003815481101515611ace57fe5b906000526020600020900154600360026000876000191660001916815260200190815260200160002060030154815481101515611b0757fe5b9060005260206000209001816000191690555060026000856000191660001916815260200190815260200160002060030154600260006003600160038054905003815481101515611b5457fe5b90600052602060002090015460001916600019168152602001908152602001600020600301819055506003805480919060019003611b9291906125fe565b5060019250611bae565b818060010192505061197e565b600092505b505092915050565b600080611bc161262a565b600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206002016040805190810160405290816000820154600019166000191681526020016001820160009054906101000a900460ff1615151515815250509050806000015181602001519250925050915091565b6000600380549050905090565b611c67336121f1565b565b611c723361138a565b1515611c7d57600080fd5b611c868161224b565b50565b6000806000611c9661242c565b611c9e612649565b339350600073ffffffffffffffffffffffffffffffffffffffff16600160008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16141515611d3e57600080fd5b600160038054806001018281611d549190612498565b916000526020600020900160008b90919091509060001916905503925060a0604051908101604052808881526020018781526020016000151581526020018481526020018a815250915081600260008a600019166000191681526020019081526020016000206000820151816000019080519060200190611dd69291906124c4565b506020820151816001019080519060200190611df39291906124c4565b5060408201518160020160006101000a81548160ff021916908315150217905550606082015181600301556080820151816004019080519060200190611e3a929190612544565b509050506080604051908101604052808573ffffffffffffffffffffffffffffffffffffffff1681526020018a815260200160408051908101604052808b60001916815260200160001515815250815260200160408051908101604052806000604051805910611ea75750595b908082528060200260200182016040525081526020016000604051805910611ecc5750595b9080825280602002602001820160405250815250815250905080600160008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506020820151816001019080519060200190611f88929190612544565b506040820151816002016000820151816000019060001916905560208201518160010160006101000a81548160ff02191690831515021790555050506060820151816004016000820151816000019080519060200190611fe992919061269a565b5060208201518160010190805190602001906120069291906126ed565b505050905050600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060040160000180548060010182816120639190612498565b916000526020600020900160008a90919091509060001916905550600160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060040160010180548060010182816120d591906125c4565b91600052602060002090602091828204019190066000909190916101000a81548160ff0219169083151502179055505087600019168473ffffffffffffffffffffffffffffffffffffffff167f0afd345e5552dca2dde02144fd1f9cc0da4b075996ba056c026e7f8b34bfd4aa60405160405180910390a36001945050505050949350505050565b60008073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415151561219a57600080fd5b8260000160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff16905092915050565b6122058160006122a590919063ffffffff16565b8073ffffffffffffffffffffffffffffffffffffffff167f3525e22824a8a7df2c9a6029941c824cf95b6447f1e13d5128fd3826d35afe8b60405160405180910390a250565b61225f81600061235490919063ffffffff16565b8073ffffffffffffffffffffffffffffffffffffffff167f47d1c22a25bb3a5d4e481b9b1e6944c2eade3181a0a20b495ed61d35b5323f2460405160405180910390a250565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff16141515156122e157600080fd5b6122eb828261215d565b15156122f657600080fd5b60008260000160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055505050565b600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161415151561239057600080fd5b61239a828261215d565b1515156123a657600080fd5b60018260000160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055505050565b602060405190810160405280600081525090565b602060405190810160405280600081525090565b60a060405190810160405280612440612793565b815260200161244d612793565b81526020016000151581526020016000815260200161246a6127a7565b81525090565b602060405190810160405280600081525090565b602060405190810160405280600081525090565b8154818355818115116124bf578183600052602060002091820191016124be91906127bb565b5b505050565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f1061250557805160ff1916838001178555612533565b82800160010185558215612533579182015b82811115612532578251825591602001919060010190612517565b5b50905061254091906127e0565b5090565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f1061258557805160ff19168380011785556125b3565b828001600101855582156125b3579182015b828111156125b2578251825591602001919060010190612597565b5b5090506125c091906127e0565b5090565b8154818355818115116125f957601f016020900481601f016020900483600052602060002091820191016125f891906127e0565b5b505050565b8154818355818115116126255781836000526020600020918201910161262491906127bb565b5b505050565b6040805190810160405280600080191681526020016000151581525090565b60c060405190810160405280600073ffffffffffffffffffffffffffffffffffffffff16815260200161267a6127a7565b8152602001612687612805565b8152602001612694612824565b81525090565b8280548282559060005260206000209081019282156126dc579160200282015b828111156126db5782518290600019169055916020019190600101906126ba565b5b5090506126e991906127bb565b5090565b82805482825590600052602060002090601f016020900481019282156127825791602002820160005b8382111561275357835183826101000a81548160ff0219169083151502179055509260200192600101602081600001049283019260010302612716565b80156127805782816101000a81549060ff0219169055600101602081600001049283019260010302612753565b505b50905061278f919061284a565b5090565b602060405190810160405280600081525090565b602060405190810160405280600081525090565b6127dd91905b808211156127d95760008160009055506001016127c1565b5090565b90565b61280291905b808211156127fe5760008160009055506001016127e6565b5090565b90565b6040805190810160405280600080191681526020016000151581525090565b604080519081016040528061283761287a565b815260200161284461288e565b81525090565b61287791905b8082111561287357600081816101000a81549060ff021916905550600101612850565b5090565b90565b602060405190810160405280600081525090565b6020604051908101604052806000815250905600a165627a7a7230582077606c231c33e874abbf75f0ae26789c28ba838ec59033e6bd487ace1d347c120029",
"storage": {
"0x0000000000000000000000000000000000000000000000000000000000000000": "0x000000000000000000000000000000000000000000000000000000000000000f",
"0x0000000000000000000000000000000000000000000000000000000000000001": "0x0000000000000000000000000000000000000000000000000000000000000000",
"0x0000000000000000000000000000000000000000000000000000000000000002": "0x0000000000000000000000000000000000000000000000000000000000000001",
"0x0000000000000000000000000000000000000000000000000000000000000004": "0x000000000000000000000000ffFFFfFFffFfffffFffFFfFFFFFFFFFff0000003"
}
},
"0xfffffffffffffffffffffffffffffffff0000002": {
"balance": "1000000000000000000000000000",
"code": "0x60606040526004361061008e576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff16806334443b9a146100935780636d3a3f8d146100e8578063819f163a1461010a578063868c09691461012c57806397ea081914610172578063bf64e0c5146101c7578063f36944241461022a578063fa256bcc14610253575b600080fd5b341561009e57600080fd5b6100a66102a0565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b6100f06102c6565b604051808215151515815260200191505060405180910390f35b61011261055b565b604051808215151515815260200191505060405180910390f35b610158600480803573ffffffffffffffffffffffffffffffffffffffff169060200190919050506107d9565b604051808215151515815260200191505060405180910390f35b341561017d57600080fd5b610185610b1f565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34156101d257600080fd5b6101e86004808035906020019091905050610b45565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b341561023557600080fd5b61023d610b84565b6040518082815260200191505060405180910390f35b341561025e57600080fd5b61028a600480803573ffffffffffffffffffffffffffffffffffffffff16906020019091905050610b89565b6040518082815260200191505060405180910390f35b600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60008060003360008060008092506000805490509150600090505b8181101561036d576000818154811015156102f857fe5b906000526020600020900160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff161415610360576001925061036d565b80806001019150506102e1565b6001151583151514151561038057600080fd5b6000805490509550600094505b8585101561054e576000858154811015156103a457fe5b906000526020600020900160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161415610541573373ffffffffffffffffffffffffffffffffffffffff166108fc61042633610ba1565b9081150290604051600060405180830381858888f19350505050151561044b57600080fd5b6000600460003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020819055506000600187038154811015156104a257fe5b906000526020600020900160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff166000868154811015156104dd57fe5b906000526020600020900160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550600080548091906001900361053b9190610c0d565b5061054e565b848060010195505061038d565b6001965050505050505090565b6000803360008060008092506000805490509150600090505b818110156106005760008181548110151561058b57fe5b906000526020600020900160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614156105f35760019250610600565b8080600101915050610574565b6000151583151514151561061357600080fd5b3360011515600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff166366f57632836000604051602001526040518263ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050602060405180830381600087803b15156106dd57600080fd5b6102c65a03f115156106ee57600080fd5b50505060405180519050151514151561070657600080fd5b600154341015151561071757600080fd5b60015434111561076957600154340395503373ffffffffffffffffffffffffffffffffffffffff166108fc879081150290604051600060405180830381858888f19350505050151561076857600080fd5b5b6000805480600101828161077d9190610c39565b9160005260206000209001600033909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550506001965050505050505090565b60008060008360008060008092506000805490509150600090505b818110156108805760008181548110151561080b57fe5b906000526020600020900160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614156108735760019250610880565b80806001019150506107f4565b6001151583151514151561089357600080fd5b3360011515600260009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663855a6e73836000604051602001526040518263ffffffff167c0100000000000000000000000000000000000000000000000000000000028152600401808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001915050602060405180830381600087803b151561095d57600080fd5b6102c65a03f1151561096e57600080fd5b50505060405180519050151514151561098657600080fd5b6000805490509650600095505b86861015610b0f576000868154811015156109aa57fe5b906000526020600020900160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168973ffffffffffffffffffffffffffffffffffffffff161415610b02578873ffffffffffffffffffffffffffffffffffffffff166108fc610a2c33610ba1565b9081150290604051600060405180830381858888f193505050501515610a5157600080fd5b600060018803815481101515610a6357fe5b906000526020600020900160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16600087815481101515610a9e57fe5b906000526020600020900160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506000805480919060019003610afc9190610c0d565b50610b0f565b8580600101965050610993565b6001975050505050505050919050565b600360009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b600081815481101515610b5457fe5b90600052602060002090016000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b606481565b60046020528060005260406000206000915090505481565b60006064600460008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054101515610c02576002600154811515610bfa57fe5b049050610c08565b60015490505b919050565b815481835581811511610c3457818360005260206000209182019101610c339190610c65565b5b505050565b815481835581811511610c6057818360005260206000209182019101610c5f9190610c65565b5b505050565b610c8791905b80821115610c83576000816000905550600101610c6b565b5090565b905600a165627a7a723058202ce7c254b71ae85afa5bc06563caa3788ca095928583f20943a64e2df0185d7a0029",
"storage": {
"0x0000000000000000000000000000000000000000000000000000000000000000": "0x0000000000000000000000000000000000000000000000000000000000000000",
"0x0000000000000000000000000000000000000000000000000000000000000001": "0x0000000000000000000000000000000000000000000000000DE0B6B3A7640000",
"0x0000000000000000000000000000000000000000000000000000000000000002": "0x000000000000000000000000ffFFFfFFffFfffffFffFFfFFFFFFFFFff0000003",
"0x0000000000000000000000000000000000000000000000000000000000000003": "0x000000000000000000000000fFffffffffFfFFffFffFfFFfFfffFfFff0000001"
}
},
"0xfffffffffffffffffffffffffffffffff0000003": {
"balance": "1000000000000000000000000000",
"code": "0x606060405260043610610169576000357c0100000000000000000000000000000000000000000000000000000000900463ffffffff16806218449a1461016e578063295a5212146101d15780632a6a46ef146101fa5780632d7e8e5d1461022357806335b8e820146102bf57806342cbb15c1461032257806352bd614c1461034b57806357e8fcb31461037857806366e10366146103a55780636dd7d8ea146103ce5780637ba2dd851461041f5780637be20a7b146104ad578063855a6e73146104d657806387646214146105275780638c65c81f1461058a5780639ab24eb0146106de578063ad4c4f521461072b578063b1a0ad9914610788578063bad58d57146107b1578063bd78f9141461080e578063be4d488b14610868578063c399d66f14610895578063c4fed465146108ba578063c55f8f76146108e7578063d5481eac146108fc578063ed698e4714610959578063f03d0512146109e7578063fda117a314610a10575b600080fd5b341561017957600080fd5b61018f6004808035906020019091905050610a39565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b34156101dc57600080fd5b6101e4610a99565b6040518082815260200191505060405180910390f35b341561020557600080fd5b61020d610a9f565b6040518082815260200191505060405180910390f35b341561022e57600080fd5b6102446004808035906020019091905050610b72565b6040518080602001828103825283818151815260200191508051906020019080838360005b83811015610284578082015181840152602081019050610269565b50505050905090810190601f1680156102b15780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34156102ca57600080fd5b6102e06004808035906020019091905050610c51565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b341561032d57600080fd5b610335610cb5565b6040518082815260200191505060405180910390f35b341561035657600080fd5b61035e610cbd565b604051808215151515815260200191505060405180910390f35b341561038357600080fd5b61038b610cef565b604051808215151515815260200191505060405180910390f35b34156103b057600080fd5b6103b8610d70565b6040518082815260200191505060405180910390f35b34156103d957600080fd5b610405600480803573ffffffffffffffffffffffffffffffffffffffff16906020019091905050610d75565b604051808215151515815260200191505060405180910390f35b341561042a57600080fd5b610432611172565b6040518080602001828103825283818151815260200191508051906020019080838360005b83811015610472578082015181840152602081019050610457565b50505050905090810190601f16801561049f5780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34156104b857600080fd5b6104c061123b565b6040518082815260200191505060405180910390f35b34156104e157600080fd5b61050d600480803573ffffffffffffffffffffffffffffffffffffffff16906020019091905050611268565b604051808215151515815260200191505060405180910390f35b341561053257600080fd5b61054860048080359060200190919050506112fe565b604051808273ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390f35b341561059557600080fd5b6105ab6004808035906020019091905050611333565b604051808515151515815260200180602001806020018481526020018381038352868181546001816001161561010002031660029004815260200191508054600181600116156101000203166002900480156106485780601f1061061d57610100808354040283529160200191610648565b820191906000526020600020905b81548152906001019060200180831161062b57829003601f168201915b50508381038252858181546001816001161561010002031660029004815260200191508054600181600116156101000203166002900480156106cb5780601f106106a0576101008083540402835291602001916106cb565b820191906000526020600020905b8154815290600101906020018083116106ae57829003601f168201915b5050965050505050505060405180910390f35b34156106e957600080fd5b610715600480803573ffffffffffffffffffffffffffffffffffffffff1690602001909190505061136e565b6040518082815260200191505060405180910390f35b341561073657600080fd5b610786600480803590602001908201803590602001908080601f016020809104026020016040519081016040528093929190818152602001838380828437820191505050505050919050506113d2565b005b341561079357600080fd5b61079b611602565b6040518082815260200191505060405180910390f35b34156107bc57600080fd5b61080c600480803590602001908201803590602001908080601f01602080910402602001604051908101604052809392919081815260200183838082843782019150505050505091905050611607565b005b341561081957600080fd5b6108666004808035906020019082018035906020019080806020026020016040519081016040528093929190818152602001838360200280828437820191505050505050919050506116a9565b005b341561087357600080fd5b61087b61179a565b604051808215151515815260200191505060405180910390f35b34156108a057600080fd5b6108b8600480803515159060200190919050506117f2565b005b34156108c557600080fd5b6108cd61180f565b604051808215151515815260200191505060405180910390f35b34156108f257600080fd5b6108fa611822565b005b341561090757600080fd5b610957600480803590602001908201803590602001908080601f016020809104026020016040519081016040528093929190818152602001838380828437820191505050505050919050506118b9565b005b341561096457600080fd5b61096c611a59565b6040518080602001828103825283818151815260200191508051906020019080838360005b838110156109ac578082015181840152602081019050610991565b50505050905090810190601f1680156109d95780820380516001836020036101000a031916815260200191505b509250505060405180910390f35b34156109f257600080fd5b6109fa611af7565b6040518082815260200191505060405180910390f35b3415610a1b57600080fd5b610a23611afe565b6040518082815260200191505060405180910390f35b600080610a44611b05565b90506008600082815260200190815260200160002060040183600581101515610a6957fe5b6002020160000160019054906101000a900473ffffffffffffffffffffffffffffffffffffffff16915050919050565b60005481565b600080600090505b6005811015610b4a573373ffffffffffffffffffffffffffffffffffffffff1660086000610ad3611b05565b815260200190815260200160002060040182600581101515610af157fe5b6002020160000160019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff161415610b3d57809150610b6e565b8080600101915050610aa7565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff91505b5090565b610b7a611e92565b6000610b84611b05565b90506008600082815260200190815260200160002060040183600581101515610ba957fe5b600202016001018054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015610c445780601f10610c1957610100808354040283529160200191610c44565b820191906000526020600020905b815481529060010190602001808311610c2757829003601f168201915b5050505050915050919050565b600080610c5c611b05565b90506008600082815260200190815260200160002060000183815481101515610c8157fe5b906000526020600020900160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16915050919050565b600043905090565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff610ce8610a9f565b1415905090565b6000806000610cfc611b05565b9150600090505b6005811015610d6657600015156008600084815260200190815260200160002060040182600581101515610d3357fe5b6002020160000160009054906101000a900460ff1615151415610d595760009250610d6b565b8080600101915050610d03565b600192505b505090565b600381565b600080600060011515610d8757600080fd5b600160009054906101000a900460ff161515610da257600080fd5b6000151560086000610db2611b05565b815260200190815260200160002060020160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060009054906101000a900460ff161515141515610e1c57600080fd5b610e24611b05565b915060006008600084815260200190815260200160002060010160008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020541415610efa57600860008381526020019081526020016000206000018054806001018281610eaa9190611ea6565b9160005260206000209001600086909190916101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550505b6008600083815260200190815260200160002060010160008573ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000206000815480929190600101919050555060016008600084815260200190815260200160002060020160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff021916908315150217905550600090505b600581101561115c578373ffffffffffffffffffffffffffffffffffffffff16600860008481526020019081526020016000206004018260058110151561101157fe5b6002020160000160019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16141561105e576001925061116b565b600073ffffffffffffffffffffffffffffffffffffffff16600860008481526020019081526020016000206004018260058110151561109957fe5b6002020160000160019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16141561114f5783600860008481526020019081526020016000206004018260058110151561110157fe5b6002020160000160016101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055506001925061116b565b8080600101915050610fce565b6111668285611b1b565b600192505b5050919050565b61117a611e92565b6000611184611b05565b905060086000828152602001908152602001600020600e018054600181600116156101000203166002900480601f0160208091040260200160405190810160405280929190818152602001828054600181600116156101000203166002900480156112305780601f1061120557610100808354040283529160200191611230565b820191906000526020600020905b81548152906001019060200180831161121357829003601f168201915b505050505091505090565b600080611246611b05565b9050600860008281526020019081526020016000206000018054905091505090565b600080600090505b60058110156112f3578273ffffffffffffffffffffffffffffffffffffffff1660028260058110151561129f57fe5b0160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1614156112e657600191506112f8565b8080600101915050611270565b600091505b50919050565b60028160058110151561130d57fe5b016000915054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60086020528060005260406000206000915090508060030160009054906101000a900460ff169080600e019080600f01908060110154905084565b60006008600061137c611b05565b815260200190815260200160002060010160008373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549050919050565b60006113dc611b05565b9050816040518082805190602001908083835b60208310151561141457805182526020820191506020810190506020830392506113ef565b6001836020036101000a03801982511681845116808217855250505050505090500191505060405180910390206000191660086000838152602001908152602001600020600f0160405180828054600181600116156101000203166002900480156114b65780601f106114945761010080835404028352918201916114b6565b820191906000526020600020905b8154815290600101906020018083116114a2575b50509150506040518091039020600019161415156114d3576115fe565b8160086000838152602001908152602001600020600f0190805190602001906114fd929190611ed2565b5060016008600083815260200190815260200160002060100160003373ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060006101000a81548160ff0219169083151502179055506008600082815260200190815260200160002060110160008154809291906001019190505550600360086000838152602001908152602001600020601101541015156115fd5760086000828152602001908152602001600020600f0160086000838152602001908152602001600020600e0190805460018160011615610100020316600290046115fb929190611f52565b505b5b5050565b600581565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff611632610a9f565b1415151561163f57600080fd5b611647611b05565b905060011515611655610cef565b151514151561166357600080fd5b8160086000838152602001908152602001600020600e01908051906020019061168d929190611ed2565b5081600790805190602001906116a4929190611ed2565b505050565b60006103e843111515156116bc57600080fd5b600582511415156116cc57600080fd5b60016008600080815260200190815260200160002060030160006101000a81548160ff021916908315150217905550600090505b600581101561179657818181518110151561171757fe5b90602001906020020151600860008081526020019081526020016000206004018260058110151561174457fe5b6002020160000160016101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055508080600101915050611700565b5050565b60008060006117a7611b05565b91506117b1610a9f565b905060086000838152602001908152602001600020600401816005811015156117d657fe5b6002020160000160009054906101000a900460ff169250505090565b80600160006101000a81548160ff02191690831515021790555050565b600160009054906101000a900460ff1681565b6000600160009054906101000a900460ff1615151561184057600080fd5b6000151560086000611850611b05565b815260200190815260200160002060030160009054906101000a900460ff16151514151561187d57600080fd5b611885611b05565b905060016008600083815260200190815260200160002060030160006101000a81548160ff02191690831515021790555050565b60008060007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff6118e7610a9f565b141515156118f457600080fd5b6118fc611b05565b9250611906610a9f565b91506001600860008581526020019081526020016000206004018360058110151561192d57fe5b6002020160000160006101000a81548160ff02191690831515021790555083600860008581526020019081526020016000206004018360058110151561196f57fe5b600202016001019080519060200190611989929190611ed2565b5060011515611996610cef565b15151415611a5357600090505b6005811015611a525760086000848152602001908152602001600020600401816005811015156119cf57fe5b6002020160000160019054906101000a900473ffffffffffffffffffffffffffffffffffffffff16600282600581101515611a0657fe5b0160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555080806001019150506119a3565b5b50505050565b60078054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015611aef5780601f10611ac457610100808354040283529160200191611aef565b820191906000526020600020905b815481529060010190602001808311611ad257829003601f168201915b505050505081565b6206978081565b6250334081565b60006250334043811515611b1557fe5b04905090565b60008060008060009350600860008781526020019081526020016000206004016000600581101515611b4957fe5b6002020160000160019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1692506008600087815260200190815260200160002060010160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020549150600190505b6005811015611ce6576008600087815260200190815260200160002060040181600581101515611bfa57fe5b6002020160000160019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1692506008600087815260200190815260200160002060010160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054821115611cd9576008600087815260200190815260200160002060010160008473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000205491508093505b8080600101915050611bce565b6008600087815260200190815260200160002060040184600581101515611d0957fe5b6002020160000160019054906101000a900473ffffffffffffffffffffffffffffffffffffffff1692506008600087815260200190815260200160002060010160008673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002054821015611e8a57846008600088815260200190815260200160002060040185600581101515611db257fe5b6002020160000160016101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060006008600088815260200190815260200160002060040185600581101515611e1c57fe5b6002020160000160006101000a81548160ff02191690831515021790555060206040519081016040528060008152506008600088815260200190815260200160002060040185600581101515611e6e57fe5b600202016001019080519060200190611e88929190611ed2565b505b505050505050565b602060405190810160405280600081525090565b815481835581811511611ecd57818360005260206000209182019101611ecc9190611fd9565b5b505050565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10611f1357805160ff1916838001178555611f41565b82800160010185558215611f41579182015b82811115611f40578251825591602001919060010190611f25565b5b509050611f4e9190611fd9565b5090565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282601f10611f8b5780548555611fc8565b82800160010185558215611fc857600052602060002091601f016020900482015b82811115611fc7578254825591600101919060010190611fac565b5b509050611fd59190611fd9565b5090565b611ffb91905b80821115611ff7576000816000905550600101611fdf565b5090565b905600a165627a7a7230582089d16f46092d13c156bd2c576978bb36fcacc35d45b058059ed6bc2d84c1efb60029",
"storage": {
"0x0000000000000000000000000000000000000000000000000000000000000000": "0x0000000000000000000000000000000000000000000000000000000000000000",
"0x0000000000000000000000000000000000000000000000000000000000000001": "0x0000000000000000000000000000000000000000000000000000000000000001"
}
}
},
"coinbase":"0x0000000000000000000000000000000000000000",
"timestamp": "0x00",
"parentHash":"0x0000000000000000000000000000000000000000000000000000000000000000",
"extraData": "",
"config":{
"chainId":2
},
"gasLimit": "0xc845880"
}
The above fields should be fine for most purposes, although we'd recommend changing the nonce
to
some random value so you prevent unknown remote nodes from being able to connect to you. If you'd
like to pre-fund some accounts for easier testing, you can populate the alloc
field with account
configs:
"alloc": {
"0x0000000000000000000000000000000000000001": {"balance": "111111111"},
"0x0000000000000000000000000000000000000002": {"balance": "222222222"}
}
With the genesis state defined in the above JSON file, you'll need to initialize every usechain node
with it prior to starting it up to ensure all blockchain parameters are correctly set:
$ used init path/to/genesis.json
Creating the rendezvous point
With all nodes that you want to run initialized to the desired genesis state, you'll need to start a
bootstrap node that others can use to find each other in your network and/or over the internet. The
clean way is to configure and run a dedicated bootnode:
$ bootnode --genkey=boot.key
$ bootnode --nodekey=boot.key
With the bootnode online, it will display an enode
URL
that other nodes can use to connect to it and exchange peer information. Make sure to replace the
displayed IP address information (most probably [::]
) with your externally accessible IP to get the
actual enode
URL.
Note: You could also use a full fledged usechain node as a bootnode, but it's the less recommended way.
Starting up your member nodes
With the bootnode operational and externally reachable (you can try telnet <ip> <port>
or nc -v <ip> <port>
to ensure
it's indeed reachable), start every subsequent usechain node pointed to the bootnode for peer discovery
via the --bootnodes
flag. It will probably also be desirable to keep the data directory of your
private network separated, so do also specify a custom --datadir
flag.
$ used --datadir=path/to/custom/data/folder --bootnodes=<bootnode-enode-url-from-above>
Note: Since your network will be completely cut off from the main and test networks, you'll also
need to configure a miner to process transactions and create new blocks for you.
Running a private miner
Mining on the public usechain network is a complex task as it's only feasible using GPUs, requiring
an OpenCL or CUDA enabled ethminer
instance. For information on such a setup, please consult the
EtherMining subreddit and the Genoil miner
repository.
In a private network setting however, a single CPU miner instance is more than enough for practical
purposes as it can produce a stable stream of blocks at the correct intervals without needing heavy
resources (consider running on a single thread, no need for multiple ones either). To start a usechain
instance for mining, run it with all your usual flags, extended by:
$ used <usual-flags> --mine --minerthreads=1 --usebase=0x0000000000000000000000000000000000000000
Which will start mining blocks and transactions on a single CPU thread, crediting all proceedings to
the account specified by --usebase
. You can further tune the mining by changing the default gas
limit blocks converge to (--targetgaslimit
) and the price transactions are accepted at (--gasprice
).
Contribution
Thank you for considering to help out with the source code! We welcome contributions from
anyone on the internet, and are grateful for even the smallest of fixes!
If you'd like to contribute to go-usechain, please fork, fix, commit and send a pull request
for the maintainers to review and merge into the main code base. If you wish to submit more
complex changes though, please check up with the core devs first on our gitter channel
to ensure those changes are in line with the general philosophy of the project and/or get some
early feedback which can make both your efforts much lighter as well as our review and merge
procedures quick and simple.
Please make sure your contributions adhere to our coding guidelines:
- Code must adhere to the official Go formatting guidelines (i.e. uses gofmt).
- Code must be documented adhering to the official Go commentary guidelines.
- Pull requests need to be based on and opened against the
master
branch.
- Commit messages should be prefixed with the package(s) they modify.
- E.g. "eth, rpc: make trace configs optional"
Please see the Developers' Guide
for more details on configuring your environment, managing project dependencies and testing procedures.
License
The go-usechain library (i.e. all code outside of the cmd
directory) is licensed under the
GNU Lesser General Public License v3.0, also
included in our repository in the COPYING.LESSER
file.
The go-usechain binaries (i.e. all code inside of the cmd
directory) is licensed under the
GNU General Public License v3.0, also included
in our repository in the COPYING
file.
contributions adhere to our coding guidelines:
- Code must adhere to the official Go formatting guidelines (i.e. uses gofmt).
- Code must be documented adhering to the official Go commentary guidelines.
- Pull requests need to be based on and opened against the
master
branch.
- Commit messages should be prefixed with the package(s) they modify.
- E.g. "eth, rpc: make trace configs optional"
Please see the Developers' Guide
for more details on configuring your environment, managing project dependencies and testing procedures.