TeamEmpireCoin / EmpireCoin

EmpireCoin is an experimental cryptocurrency where players vote on outcomes to win coins
http://empirecoin.org
MIT License
2 stars 2 forks source link

Add "getnewvotingaddresses" RPC command. #14

Closed joeyfrich closed 8 years ago

joeyfrich commented 8 years ago

For web wallets, many users will be on the same wallet.dat To allow each user to have their own voting addresses, many voting addresses should be created in the wallet. A command like: ./EmpireCoind -testnet getnewvotingaddresses 100 should keep generating addresses until 100 assorted voting addresses have been created and saved. This way a web wallet operator can run this RPC command once in a while to get a bunch of unallocated voting addresses which can be given out to users upon signup.

xmadisco commented 8 years ago

See pull request #20

I think that fix is superior to this because generating a huge 'random' assortment will both bloat the wallet store on disk and generally not be close to an even distribution of voting addresses per nation.

With an RPC that generates a single address for a specified nation, the caller can guarantee a specified number of addresses for each desired nation in a more controlled manner by calling it as many times as needed for each nation.

For example, on a new user web sign-up, it can be called once for each nation and assign those to the new user.