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)
0 comments
Reply