How to encrypt ChainCoin wallet.dat in a masternode from command-line (Linux)

I am going to show everyone how to Encrypt your wallet.dat in ChainCoin. ChainCoin is a clone of DASH, so this tutorial works for many other coins as well.

First log into your masternode

Then create a passphrase for your wallet with this command:

without the quotes

chaincoin-cli encryptwallet 'my-passphrase'

Now your wallet will be encrypted with this passphrase. Do not lose your passphrase or you will be unable to access your funds.

Your ChainCoin server/daemon will be stopped after you add a passphrase to your wallet.

Start your ChainCoin daemon again:

chaincoind --daemon

Now we are going to backup our private key

Keep the private key safe and do not lose it


without the quotes

chaincoind walletpassphrase "passphrase" 120

120 = timeout (number of seconds). Once this timeout expires, you will need to enter your passphrase again to access the wallet and perform transactions

Type this to dump your private key:

without the quotes

chaincoind getaccountaddress 0
chaincoind dumpprivkey 'wallet-address'

Save your private key and you are done!

**For the masternode users:

If you have a masternode and would like to run it, the command to start a masternode with an encrypted wallet is:

without the quotes

chaincoind walletpassphrase 'passphrase' 120
chaincoind masternode start 'passphrase'

You have successfully encrypted and backed up your wallet!