Skip to content

Instantly share code, notes, and snippets.

@flux627
Created May 3, 2017 14:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save flux627/f16ad0daf02c3fe7fe58ce9d39b753ee to your computer and use it in GitHub Desktop.
Save flux627/f16ad0daf02c3fe7fe58ce9d39b753ee to your computer and use it in GitHub Desktop.
Recovering bitshares 1.0 funds (extracted from archive.org)

Recover Funds

The purpose of this article is to help early users recover funds that seem to be lost due to

  • software bugs that made the keyring loose keys
  • inconvinient backup solutions
  • having the same wallet used on several machines

As long as you kept at leat one backup (including your passphrase) you are able to recover your keys and no funds are lost

Terminology

  • account: An account is similar to an deposit box and should be registered on the blockchain

    Every transactions to you account name is sent to an address which is
    controlled by a dereived key from the account private key
  • wallet: The wallet is a set of account names and corresponding private keys.

    When you first created an account name, the private key for that account key
    is dereived from the wallet private key and can thus be recalculated from the wallet private key.

Requirements

In order to recover your funds you need the so called wallet private key which is stored in your wallet backup in an encrypted format. Please note that, in contrast to Bitcoin, the BitShares software dereives ALL keys deterministically (except the wallet private key) and can thus recover all private keys that have ever been used in your wallet (including account keys and transaction keys). All keys that are used in the software are derived from this wallet private key and two backup strategies exist for a wallet.

In-app backup function

The BitSharesX software has an easy-to-use backup solution built into it. If you used this to backup your keys you should own a file in JSON format which contains the wallet private key in an encrypted format. Please ensure your also remember the passphrase you chose to unlock the wallet once you created the wallet. You can recover from this backup using an in-app recover/import functionality. Please make sure not to loose your current wallet at the reimport WILL overwrite your default wallet.

Plain copy of the wallets directory

The BitSharesX software stores the encrypted keys in a binary database located in you%APPDATA% directory on your hard drive. If you have a copy of this folder (usually called "default" for GUI users), you can also recove you wallet private key by simply moving the default wallet back into the%APPDATA% directoy you had it from. Make sure to not overwrite any existing folder. You can now safely restart your wallet.

Howto

This section describes the steps you might need to perform in order to make your funds available again. You may need to go through all or them.

Rescanning the blockchain

As TITAN uses derived keys you might need to rescan the whole blockchain. In order to do so, go to the console and type:

rescan

Press enter. The wallet immediatelly returns an OK, but might use several minutes (up to 60 minutes depending on your machine) to rescan the whole blockchain. You can see the progress using:

getinfo

The relevant return line is wallet_scan_progress.

If the scan is complete (100%) and you funds are not back yet please proceed to the next step.

Recovering lost account

If you have created a registered or local account(s) within the wallet and lost access to that account(s) you can recreate it/them using the following command:

wallet_recover_accounts 10

This command attempts to recover up to 10 accounts in your wallet. If the recovery was succcessfull you might need to rescan the whole blockchain again.

Regenerate account transaction keys

In order to recover lost keys in your wallet due to bugs in the software or misuse, you can try

wallet_regenerate_keys ACCOUNT-NAME 1000

This command will regenerate 1000 TITAN keys for the given account name. If you already have more than 1000 transactions in your account, you might need to increase that number. You might also need to rescan the whole blockchain.

Regenerate account transaction details

If you lost have lost a transaction on the market and see an UNKOWN recepient or memo in you transaction history you may want to try the following:

wallet_recover_transaction TXID

with TXID beeing the transaction id (prefix) of that particular (UNKOWN) transaction. A blockchain rescan is not necessary.

Still missing funds

If you are still missing funds proceed as follows:

  • Stay calm, the blockhain never losses anything
  • Make sure your have a backup of your backup
  • Contact the community at the bitsharestalk forum
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment