-
Notifications
You must be signed in to change notification settings - Fork 0
Wallets
If you already have the executable built, skip this step. Navigate to project_aurum/cmd/client/main/
and run:
go build -o client
Wherever your executable is (if you followed the last step it should be in the same directory), run:
./client -s
This should create your wallet, named aurum_wallet.json
. It will also output three pieces of key information about your wallet:
- Wallet Address
- Balance
- State Nonce
Your Wallet Address is your public identity on the blockchain. If anyone wishes to send you Aurum, this is the address they should use. Think of it as a traditional routing number, except in this case you are your own bank.
The balance is pretty self explanatory. It should be zero initially (we'll get to updating next).
A nonce is a "number used only once". It represents the "state" of your wallet. Every time there is a change to your wallet's balance, the nonce goes up by one, and is irreversible. The maximum state nonce is 2^64, which is highly unlikely to be reached. The purpose of this nonce is to add a layer of security to your contracts. (see: Contracts)
To update your wallet, run:
./client -u --producer=xxx.xxx.xxx.xxx:x
,
where the x's represent the ip:port
of the producer.
This will send an account info request to the producer. If your wallet was not made pre-genesis your wallet will probably not be recognized on the blockchain. If your wallet was made post-genesis, then your wallet will only be registered once someone sends Aurum to your wallet address and the block containing that contract has been produced.
Once your account is registered on the blockchain, you may run update as much as you wish. Assuming your wallet is out of sync with the blockchain, running -u
will update the balance and state nonce of your wallet to the truth every time.