From 8b28e224ed674494865486fe695d717b4cc33d3e Mon Sep 17 00:00:00 2001 From: Ben Davenport Date: Fri, 1 Aug 2014 00:27:29 -0700 Subject: [PATCH] Add README for examples directory --- example/README.md | 18 ++++++++++++++++++ example/recoverwallet.js | 10 +++++----- 2 files changed, 23 insertions(+), 5 deletions(-) create mode 100644 example/README.md diff --git a/example/README.md b/example/README.md new file mode 100644 index 0000000000..e0d84d74fc --- /dev/null +++ b/example/README.md @@ -0,0 +1,18 @@ +BitGoJS Examples +======= + +# Wallet Recovery Tool + +The wallet recovery tool allows you to completely recover a BitGo BIP32 multi-sig wallet +using only the user's 2 keys, without making any communication with BitGo. In the event +BitGo ceases to operate, or becomes temporarily unavailable, the tool makes it possible +to exert full control over the bitcoin in your wallet. + +To use the tool, you will need the KeyCard from your BitGo wallet, along with your +wallet passcode. If you provided +your own backup public key at wallet creation time, you will also need the private half +of the backup key. It may be necessary to scan the QR codes from the KeyCard +with a mobile phone and email the resulting text to yourself. + +Run the tool using 'node recoverwallet.js' + diff --git a/example/recoverwallet.js b/example/recoverwallet.js index 9e185411fb..ba98666a10 100644 --- a/example/recoverwallet.js +++ b/example/recoverwallet.js @@ -80,11 +80,11 @@ var collectInputs = function() { inputs.nosend = true; } - return getVariable("userKey", "Enter value from Box A: 'User Key':")() - .then(getVariable("backupKey", "Enter value from Box B: 'Backup Key':")) - .then(getVariable("bitgoKey", "Enter value from Box C: 'BitGo Public Key':")) - .then(getVariable("password", "Enter your wallet passcode:")) - .then(getVariable("destination", "Enter the bitcoin address to receive the funds:")); + return getVariable("userKey", "Enter value from Box A: 'User Key': ")() + .then(getVariable("backupKey", "Enter value from Box B: 'Backup Key': ")) + .then(getVariable("bitgoKey", "Enter value from Box C: 'BitGo Public Key': ")) + .then(getVariable("password", "Enter your wallet passcode: ")) + .then(getVariable("destination", "Enter the bitcoin address to receive the funds: ")); }; //