Last active
September 20, 2016 04:34
-
-
Save Someguy123/5013a479dea3ac8996d32642cfb902a6 to your computer and use it in GitHub Desktop.
Extract only spent private keys from a BitAddress/LiteAddress text file
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This means to build an array () based on line breaks in the file | |
# allowing us to use it with a for loop | |
LFS=' | |
' | |
# btcaddrs contains addresses that are actually used | |
addresses=($(cat btcaddrs.txt)) | |
# filter the bitaddress file btc.txt to only contain used addresses | |
# then spit out the un-quoted private keys | |
(for a in $addresses; do grep $a btc.txt; done) | awk '{ split($0,a,","); print a[3] }' | tr -d '"' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment