Bash one-liner to get the Bitcoin whitepaper directly from the blockchain

Someone encoded the whole bitcoin.pdf whitepaper in one giant transaction. You can use this command to recreate it. Requires a full node (pruned will do)

seq 0 947 | (while read -r n; do bitcoin-cli gettxout 54e48e5f5c656b26c3bca14a8c95aa583d07ebe84dde3b7dd4a78f4e4186e713 $n | jq -r '.scriptPubKey.asm' | awk '{ print $2 $3 $4 }'; done) | tr -d '\n' | cut -c 17-368600 | xxd -r -p > bitcoin.pdf

submitted by /u/imatwork2017
[link] [comments]

Comments