This file contains hidden or 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
| """ | |
| Required modules: | |
| ecdsa (pip install ecdsa) | |
| base58 (pip install base58) | |
| """ | |
| import ecdsa | |
| import base58 | |
| import hashlib | |
| from hashlib import sha256 |
This file contains hidden or 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
| """ | |
| Script discussed in the video: | |
| https://youtu.be/i2QaBjCvMN4 | |
| How to steal all bitcoin (on average 10^-60 of it per day) | |
| This script checks whether a given Bitcoin private key (int) has | |
| funds using a CSV snapshot of the blockchain ledger. | |
| This ordered CSV of currently funded addresses can be downloaded from: | |
| http://addresses.loyce.club/ |
This file contains hidden or 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
| #!/usr/bin/env python | |
| ''' Run from "electrum/lib" directory. | |
| ThomaxV started a discussion on https://bitcointalk.org/index.php?topic=274182.msg2939599#msg2939599 | |
| about changing the HD derivation logic in electrum 2. The below post: | |
| http://bitcoin.stackexchange.com/questions/37013/how-to-import-a-hd-wallet-from-an-extended-private-key | |
| confirms that the format is actually m/c/i (and not m/44'/0'/a'/c/i) | |
| so I have altered https://gist.github.com/romanz/4b32782bfc0ff4984713 accordingly: | |
| tested to work with keys/addresses exported from electrum 2.7.0 | |
| note Electrum has a "gap limit" of 20, so loop @ level "c" to get the next 20 addresses | |
| ''' |
This file contains hidden or 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
| #!/usr/bin/env python | |
| ''' Run from "electrum/lib" directory. | |
| ''' | |
| import bitcoin, mnemonic | |
| mn = raw_input("Enter mnemonic (13 words)").strip() | |
| s = mnemonic.Mnemonic.mnemonic_to_seed(mn, '') | |
| print 'seed:', repr(s) | |
| xprv, xpub = bitcoin.bip32_root(s) |
NewerOlder