Dump all bitcoin private keys

I have used this script to export all private keys in a wallet. The blockchain does not have to be synced, but the wallet obviously has to be unlocked (with walletpassphrase).

No warranty.

#!/usr/bin/env bash

while read -r address; do
  echo $address
  bitcoin-cli dumpprivkey $address
done < <(bitcoin-cli listaddressgroupings | grep -E '[13][a-zA-Z0-9]{27,34}' --only-matching --color=never)


Start a new thread

Cancel reply
Markdown. Syntax highlighting with <code lang="php"><?php echo "Hello, world!"; ?></code> etc.
DjangoPythonBitcoinTuxDebianHTML5 badgeSaltStackUpset confusedMoneyHackerUpset confusedX.OrggitFirefoxWindowMakerBashIs it worth the time?i3 window managerWagtailContainerNginxSilenceTorWorldInternet securityFont