Podcast #128: We chat with Kent C Dodds about why he loves React and discuss what life was like in the dark days before Git. Listen now.

Hot answers tagged

96

It is possible to brute force some Bitcoin addresses, because some people generate their private keys in an insecure manner. Any (non-zero) 32 bytes can be a private key. So running sha256 over a passphrase gives an apparently random, but brute force-able private key. Take sha256("sausage") for instance: $ echo -n 'sausage' | sha256sum ...


62

A compressed key is just a way of storing a public key in fewer bytes (33 instead of 65). There are no compatibility or security issues because they are precisely the same keys, just stored in a different way. The original Bitcoin software didn't use compressed keys only because their use was poorly documented in OpenSSL. They have no disadvantages other ...


50

In order to spend money sent to a Bitcoin address, you just need to find a ECDSA public key that hashes to the same 160-bit value. That will take, on average, 2160 key generations. Supposing you could generate a billion (230) per second, you need 2130 seconds. Doing this in parallel using a billion machines requires only 2100 seconds. Getting a billion of ...


45

I know this question is old, but I stumbled upon it looking how to teach myself how multisig addresses work, and I imagine others will to. So I’m going to try to explain the typical flow for creating, adding bitcoins to, and eventually spending a multisig address. This explanation is aimed at beginners, so please excuse my lack of brevity. First off, some ...


40

The green address is a third party trust trick and can help resolve most problems related to the need to wait for confirmations (slow transactions). To make it very simple : Service A publishes its green address, service B decides to trust service A. When someone send bitcoins from service A to service B, he will send from the service A green address. ...


40

As I understand it, the "stealth address" is intended to address a very specific problem. If you wish to solicit payments from the public, say by posting a donation address on your website, then everyone can see on the block chain that all those payments went to you, and perhaps try to track how you spend them. With a stealth address, you ask payers to ...


39

Two reasons: So whoever sent to your "A" address can't claim to have sent you 31 bitcoins ("See! Look on block explorer, there are two transactions sending to "A", one for 20 bitcoins and one for 11-- send me back the extra 11!") Using a new change address makes it more difficult for other people to track of how many bitcoins you have or where you're ...


36

The wiki is correct, it is a technicality. Bitcoin "balances" are actually just unspent transaction outputs (UTXOs, from previous transactions) which you have the ability to spend. In most cases, that means knowing the private key corresponding to an address which the transaction was sent to. But the address itself doesn't have a balance, it just "locks up" ...


33

If this happens, then Person B will be able to spend person A's bitcoins. However, there are only two ways this can happen: a) Person B generates the same keypair (private key) as person A or b) Person B generates a different keypair, which (public key) hashes to person A's address (a hash collision) Take a look at the specification for at bitcoin address:...


31

As the operator of the site I will try and answer the first question. Server Side The site currently runs on 4 dedicated servers, hosted in a locked cabinet. All servers run behind a dedicated cisco security appliance with intrusion detection. On the servers themselves various "booby traps" are set to alert the webmaster if an intrusion is detected. The ...


29

I calculated the answer by starting with Gavin's "bitcointools" and modifying it to track account balances. Here's what I found. Each line shows the number of addresses after the specified block was found, at the end of each month. So the 1st line is saying that after block 2543 was found at the end of Jan 2009, there were 2,439 funded addresses, and all ...


28

RIPEMD was used because it produces the shortest hashes whose uniqueness is still sufficiently assured. This allows Bitcoin addresses to be shorter. SHA256 is used as well because Bitcoin's use of a hash of a public key might create unique weaknesses due to unexpected interactions between RIPEMD and ECDSA (the public key signature algorithm). Interposing an ...


27

As is normal when doing Elliptic Curve encryption, a private key is simply a random number. In the case of secp256k1, the elliptic curve used by Bitcoin, it has to be a number between 1 and 115792089237316195423570985008687907852837564279074904382605163141518161494336 (or in hexadecimal, between 0x1 and 0xFFFFFFFF FFFFFFFF FFFFFFFF FFFFFFFE BAAEDCE6 AF48A03B ...


25

It's impossible to say for sure what's a vanity address and what's generated purely at random, but 1CFBdvaiZgZPTZERqnezAtDQJuGHKoHSzg is 34 characters with no digits in it other than the initial '1'. That may well be a vanity address. Then again on average 1 in every 515 34-character addresses you generate won't have any digits in them other than the ...


25

This is the way I see it. The total number of bitcoins that will ever be mined is 21 million. The smallest bitcoin unit is a satoshi (0.00000001 BTC). If we place all possible satoshis into a wallet of their own, we would get the maximum number of wallets that could have any balance to them (so the actual number of wallets with bitcoins is obviously less). ...


24

It is highly unlikely, you made a typo and were still able to send coins. There is a difference between an invalid address and an incorrect address. All bitcoin wallets/clients check if addresses are valid. Bitcoin addresses are the PubKeyHash encoded in Base58 with a version value and a checksum. The checksum is the leftmost 32 bits of a double hash of ...


23

It's just to get shorter addresses. Regular public keys are 65 bytes long, which is much too long to be convenient. Compressed public keys are 33 bytes and could potentially be used instead of hashes, though these are a little longer than 20-byte hashes. It also seems likely that Satoshi didn't know about compressed public keys or wasn't comfortable with ...


22

Addresses are the public key of an asymmetric key pair An address represents the public key of an asymmetric key pair.¹ The owner of the key pair can use the private key to sign transactions or messages (for example in order to prove ownership). Only by using the correct private key a valid signature may be created, which then anyone can verify as valid by ...


18

While the other answers are slightly true, there's another reason. Addresses which have been spent are inherently less secure than unspent addresses. This is because, when spending on an address, you reveal the public key to the address. This means that in order to steal those funds, you only need to find the private key, whereas normally you'd need to break ...


18

Yes, you can have two keys generate the same address. There are 2^160 possible addresses, and 2^256 possible private keys, so each address corresponds to roughly 2^(256-160)=2^96 private keys. Any of these will generate the same address and thus be able to spend the money owned by that address. Since 2^160 is so large, however, it would take a near-eternity ...


17

The reason they exist both, is because Satoshi didn't know about compressed public keys, and it was only recently discovered that they would be possible to use without compatibility problems (support only exists as of version 0.6 of the reference client). The advantage is clear: their public keys are smaller, resulting in smaller transactions on the network,...


17

Yes, you could send bitcoins directly to the public key: in fact, both Pay-to-PubKey (P2PK) and Pay-to-PubKey-Hash (P2PKH) were introduced in the first Bitcoin release. IIRC, P2PK is still used for Coinbase transactions sometimes, today. P2PK transactions are slightly bigger for outputs but significantly smaller for inputs. One advantage of P2PKH is that ...


16

Format (private keys): uncompressed: 0x80 + [32-byte secret] + [4 bytes of Hash() of previous 33 bytes], base58 encoded compressed: 0x80 + [32-byte secret] + 0x01 + [4 bytes of Hash() previous 34 bytes], base58 encoded case 1: secret (hex): 1111111111111111111111111111111111111111111111111111111111111111 uncompressed: secret (base58): ...


16

If an address begin with "1" then it's a hash of a public key, "3" for a script hash, "5" for a private uncompressed key, etc You can find a list of all prefixes here: https://en.bitcoin.it/wiki/List_of_address_prefixes


16

This seems to be a few related questions in one, so I will try to rephrase them individually and answer each one separately. First it is important to understand that a wallet is just a place to keep bitcoin addresses, in the same way that a leather wallet is just a place to keep cards and notes. Bitcoin amounts are sent to an address, not to a wallet. A ...


16

Bitcoin addresses do not actually exist on the Bitcoin network. They are an abstraction for humans to be able to easily send money to each other. What Bitcoin actually uses are transaction outputs. A transaction creates outputs which consist of the value and the output script. When you send money to someone, you are spending from an Unspent Transaction ...


14

The wiki is correct! The source you linked must have assumed that the address with the smallest encoding has version_byte=00, data=20*00, checksum=94A00911 $ encodeBase58 00000000000000000000000000000000000000000094A00911 1111111111111111111114oLvT2 Which hash length 27. This address is valid and has been used on the blockchain! But it is not the shortest ...


14

This is now explained in the current Beta Guide: Zcash has two kinds of address: a z-addr is a fully private address that uses the zero-knowledge proving system to shield a transaction and balance privacy. A t-addr (aka "transparent address") is similar to a Bitcoin address. An address can be created using: zcash-cli getnewaddress # t-addr, or ...


14

"Improbable" is an understatement. There are 2256 possible keys. In the entire universe, there are estimated to be "only" 2100 atoms. So the odds of someone else ending up with the exact same address/key as you is far, far less than the same atom, out of the entire universe, being randomly picked twice. If you are worried about an address collision, here ...


Only top voted, non community-wiki answers of a minimum length are eligible