Importing BTC/BCH into Ledger Nano S

Can and how does one import a paper wallet (private key) that contained BTC before the hardfork and now BCH as well into a ledger nano s to split them? Or do they have to be split in another wallet first and then tranfered separately? I’ve contacted Ledger support but it takes weeks to get a response.

Bitcoin library vs script to develop application

I’m curious about the development of application of Identity management in Blockchain platform, but I’m a bit confused about the technologies to use.

In short words, when is more convenient to develop an application coding in script and when is it better to use a high-level library like BitcoinJ or a service as API?

I’m a Java developer and I’m more confortable using a Java Library like bitcoinJ, but I don’t understand if, in this way, I can lose something in performance or expressivity or "semantic power" in regard to most raw-level scripting system of Bitcoin (that is a kind of assembler).

Thanks you in advance

What are the trust assumptions in –assumed-valid in bitcoin core 0.14?

Please help me understand and distinguish the trust assumptions in the following three cases shown below. Specifically, please elaborate the attacks possible (even though completely theoretical) and trust sacrificed to get the functionality.

Case 1: Bitcoin Core before 0.14 without assumed-valid and where each node does complete signature verification.

Case 2: Bitcoin Core 0.14 with the assumed-valid blocks with signature validation skipped for blocks prior to release. This means that the block signatures are correct because bitcoin-core devs signed on it.

Case 3: (Hypothetical) : Bitcoin Core 0.14 with UTXO set which has the snapshot of UTXO database. This would be done in a similar way as assumed-valid. This would skip the complete IBD and be really useful for quickstart-pruned node.

I would like to know answers to the following 2 questions:

Q1) What are the possible attacks (even though completely theoretical) which are possible in case 2 but not in case 1. Please elaborate security-model change required to shift from Case 1 to Case 2.

Q2) What are the possible attacks (even though completely theoretical) which are possible in case 3 but not in case 2.
It appears to me that security model in Case 3 is same as that of Case 2. If I trusting core devs with signature-validation, might as well trust they give the correct UTXO set.

bitcoin.rpc python library problem

I am working through Master Bitcoin. I got the bitcoin client up and running. I am now trying to access the client from python. In the example, there is a line that says from bitcoin.rpc import Rawproxy.

I get the error message no module named rpc. When I run pip freeze, I have python-bitcoinrpc==1.0 listed. Why can’t this module be found?

Store Bitcoins offline

I have some bitcoins and ether at and I am really scared of losing them.

How do I best secure them? Right now I have a paper with the code to restore my wallet, but my coins are still stored at

Wouldn’t it be better to store them completely offline? How do I do this? What is the difference of storing them at and keep a paper with the code to restore the wallet?

I guess if I store my coins at, I have to trust that they don’t go bankrupt, they don’t steal my coins, and no one hacks their servers and steal my coins.

Therefore, I guess it’s more safe to store them physically, but I don’t understand how they are stored physically. From my understanding, I just create a code that can validate that I am the owner of the coins. So if I in the future want to see my coins, I can create an online wallet using the physically stored code?

What I basically want is to store my coins offline but have a wallet where I can see exactly how many coins I can access with the offline stored code (without giving the code to an online wallet).

I have also looked at Ledger, but they are very pricey and I don’t really see the value in them, since I still have to store a code on a physically printed paper to be sure I can still access the coins in case I break or lose the Ledger.

How to produce a Hash160 bitcoin address?

How should one perform Hash160, using most basic tools?



I’m trying to figure out, how transactions work in bitcoin.

When I choose inputs for a new tx I want to make sure they belong to a specific address. However, existing txs do not specify previous outputs’ addresses, but instead they contain address’ hashes.


>> bx fetch-tx 11a1b7ac0a65bd50b7094c720aecd77cfd83d84b1707960fd00dd82a888aab5c --config /home/theo/Desktop/bx-testnet.cfg

    hash 11a1b7ac0a65bd50b7094c720aecd77cfd83d84b1707960fd00dd82a888aab5c
            address_hash f3b7278583827a049d6be894bf7f516178a0c8e6
                hash 4a3532061d43086299ae9b2409a456bb9638dff32e0858c4ccda27203fb2e4f6
                index 1
            script "[30440220146b8b5b014245a9e27e21122d4dded04c3f39c3a49ac2494743d6f6ae8efff602206d417a4be9c7431ea69699132438510ade1cf8d746607f77d114907762ed1eb301] [023dd2e892290e41bb78efce6ea30a97015ef13eaaa9ebb7b0514485fc365cc391]"
            sequence 4294967295
    lock_time 0
            address_hash a73706385fffbf18855f2aee2a6168f29dbb597e
            script "dup hash160 [a73706385fffbf18855f2aee2a6168f29dbb597e] equalverify checksig"
            value 130000000
            address_hash ad6e80394af99ece5d7701bf2f457480b93965b7
            script "dup hash160 [ad6e80394af99ece5d7701bf2f457480b93965b7] equalverify checksig"
            value 49525957813
    version 1

Say, I want to check which of the outputs can be sent from address mvm74FACaagz94rjWbNmW2EmhJdmEGcxpa
So I take its Hash160 in Python:

>>'ripemd160', hashlib.sha256("mvm74FACaagz94rjWbNmW2EmhJdmEGcxpa".encode('utf-8')).digest()).hexdigest()

That is not the result I expected: a73706385fffbf18855f2aee2a6168f29dbb597e

Meanwhile, this online service calculates hash correctly.

How do I Hash160 a bitcoin address, preferably in Python?

opening an old wallet.dat

I had about $8 USD worth of bitcoin in a wallet, and I backed up the wallet.dat to my dropbox. According to the modified date of the file this was in April 2013, so it was probaby from bitcoin qt version 0.8.1, or maybe a little earlier.

I basically left it there and haven’t done anything with bitcoin since then. Since it is worth probably at least $100 now I decided to check the exact amount.

I downloaded the latest version of bitcoin core, added the wallet.dat file to the data directory, started it with -rescan, and waited almost a month (!) for the blockchain data to get up to date. The balance showed as 0 the whole time. I thought it would update once the blockchain was totally downloaded, but it still just says 0.

Is this a problem with old vs new versions? Did I do something wrong? Next time, should I expect the balance to show a non-zero amount even if I haven’t downloaded the whole blockchain yet?