Questions tagged [hash]

This tag should be used for questions related to hashes. A hash is the output of a hash function, a function which .is a mathematically reproducible but irreversible process that takes in an arbitrary length input and produces a fixed length output. The same input will always result in the same output. Hashing is central to Bitcoin mining as well as the generation of Bitcoin addresses.

Filter by
Sorted by
Tagged with
138
votes
4answers
228k views

What are bitcoin miners really solving?

As with mining, what are the bitcoin miners really solving? I read they are solving hashes, but what does that really mean. Can we see what they are solving? Can someone give an example of what a ...
97
votes
12answers
9k views

Is there a way to set up proof-of-work systems so they would be even more useful?

One of the arguments made against Bitcoin's design choices is that it wastes resources authenticating transactions. In particular, finding small hashes is completely useless for the world. Are there ...
41
votes
1answer
11k views

How are transaction hashes calculated?

I'm trying to calculate the hash of transactions in bitcoin blocks, but I'm not getting the right answers. For example, the genesis block has a single transaction. Here's how I'm attempting to ...
36
votes
2answers
9k views

Nonce size - Will it always be big enough?

If I understand correctly, the block only has 4 bytes (32 bits) for the nonce. Is it possible for the difficulty to become high enough that there are no nonce solutions? If so, then what options does ...
32
votes
4answers
5k views

Why are hashes in the bitcoin protocol typically computed twice (double computed)?

According to the wiki specification of the bitcoin protocol, hashes are typically "computed twice". For example: hello 2cf24dba5fb0a30e26e83b2ac5b9e29e1b161e5c1fa7425e73043362938b9824 (first round of ...
27
votes
8answers
16k views

How can I generate a vanity Bitcoin address?

I once found a program that was capable of creating Bitcoin addresses with specific words in them, but can't find it now. Is there a trusted program, in the Ubuntu repositories for example, that can ...
27
votes
2answers
10k views

Why does Bitcoin use two hash functions (SHA-256 and RIPEMD-160) to create an address?

Why do we use 2 hash functions (both SHA and RIPEMD) to create an address? Why not just use one hash function?
27
votes
1answer
5k views

Why are Bitcoin addresses hashes of public keys?

Currently, Bitcoin addresses and their checksums are constructed from the public key by a using repeated hashing with SHA256 and RIPEMD160. Now I understand the reasoning behind using hashing for ...
22
votes
3answers
12k views

How do I implement a Merkle Tree?

I`m slowly implementing some Bitcoin protocols, and I'm not sure how to properly understand the Merkle Tree from the Bitcoin wiki: https://en.bitcoin.it/wiki/Protocol_specification#Merkle_Trees I have ...
20
votes
2answers
28k views

What does it mean for a cryptocurrency to be ASIC-resistant?

I guess the question I'm asking here is what does it take for an altcoin to be ASIC-resistant? What does it need to have?
19
votes
3answers
64k views

What does the mining difficulty number really mean?

I'm new to bitcoin; please bear with me. I'm looking into mining, how it works, and how to get started. I see a "mining difficulty" from many sources and list a 3 billion something number without ...
18
votes
1answer
14k views

Relationship between Hash-Rate and Difficulty

What is the algebraic relationship between Total Network Hash-Rate and Difficulty?
17
votes
4answers
15k views

How do you perform double-SHA-256 encoding?

The Bitcoin Protocol-specification gives an example of double-SHA-256 encoding. hello 2cf24dba5fb0a30e26e83b2ac5b9e29e1b161e5c1fa7425e73043362938b9824 (first round of sha-256) ...
16
votes
5answers
2k views

Is Bitcoin future-proof?

As I understand things, the security and integrity of Bitcoin rely on the assumption that its hashing is "hard" in some sense. However, in the past, processing power has increased exponentially. ...
14
votes
2answers
2k views

How many Integer Operations on a GPU are necessary for one Hash?

I thought it was the ALU OPs like here: https://bitcointalk.org/index.php?topic=7964.0 ArtForz speaks of much higher values, though: https://bitcointalk.org/index.php?topic=4689.msg68933#msg68933 ...
13
votes
2answers
12k views

What is “Script Hash” address exactly and how does it work?

I found out this address playing with blockchain https://blockchain.info/address/3NukJ6fYZJ5Kk8bPjycAnruZkE5Q7UW7i8 I found out it's something called "scripthash". How does it work exactly? How does ...
12
votes
3answers
14k views

Why are Bitcoin calculation “useless”?

The FAQ says: Why don't we use calculations that are also useful for some other purpose? To provide security for the Bitcoin network, the calculations involved need to have some very ...
12
votes
2answers
23k views

How is the network hash rate calculated?

Miners work on finding blocks but don't sent anything until they find the block. Considering that, how can sites like bitcoincharts.com display a graph of the network hash rate?
12
votes
3answers
1k views

Can the Bitcoin network be used for cracking?

I'm assuming that the Bitcoin economy is rapidly building a computing cluster capable of unprecedented amount of hash searching. Would it be possible for an attacker to leverage this to crack other ...
12
votes
2answers
955 views

How can we be sure that a new block will be found?

How do we know the HASH function will produce an output that fulfills the difficulty, i.e. is below 0000...xxxx...xxx? Is it possible that no proof will be found so that the HASH will produce that ...
12
votes
2answers
2k views

Two blocks, two transactions, same hash

Would a block containing a transaction with an identical hash as a previous transaction be considered valid? That is, if someone made a transaction for generating Bitcoins and solve two blocks with ...
12
votes
2answers
729 views

Is it possible for the network to stop finding valid blocks?

The hashing problem is by design computationally hard, because SHA-256 hashes are for all intents and purposes random strings with no direct link to their inputs, and there's no (known) way to ...
12
votes
3answers
2k views

What will happen when SHA 256 needs to be replaced?

MD5 used to be the hash algorithm. Everyone loved it, but now, not so much. What will happen to bitcoin if flaws are found in SHA256 in the future?
11
votes
5answers
3k views

how can I insert an arbitrary sha256 hash into the blockchain?

If I want to prove that I wrote a particular document before a certain point in time, it would be sufficient to generate the sha256 hash of the document and somehow arrange for that hash to appear in ...
11
votes
4answers
6k views

Where is Double hashing performed in Bitcoin?

where in the Bitcoin Protocol is SHA256(SHA256(x)) performed and why?
11
votes
2answers
6k views

Exactly how does one calculate how many BTC they will get a certain hashrate?

I am curious on how many estimated BTC I will earn at any hash rate since, I don't really think I'm really earning any BTC at 600 Mhash/s.
11
votes
2answers
2k views

Work distribution in a mining pool

How is work distributed among members of a pool? Regarding the block hashing algorithm and valid hashes of a new node, how is the set of solutions for nonces "distributed" among miners?Is a nonce, ...
11
votes
1answer
2k views

How does the CPU hashing algorithm used in Yacoin differ from scrypt?

Alt-coins are now a dime a dozen and with only minor changes to generation rates, difficulty, and algorithms, they all tend to use the SHA-256 (bitcoin) or the scrypt (litecoin/tenebrix) hashing ...
10
votes
2answers
5k views

How can I measure the total hashing power of the Bitcoin network?

Is there a way to measure what is the total hashing power of the Bitcoin network at a given time? For pooled mining it isn't a problem - one can rely on statistics provided by the pool (assuming one ...
9
votes
8answers
3k views

Can more than 1 block be solved per 10 mins on average (LONG TERM)?

I am wondering whether it is possible for a supercomputer to find the next 1000 blocks in a very short amount of time. Hypothetically, if a government agency concentrated a supercomputer on hashing, ...
9
votes
4answers
10k views

hash versus hash pointer

I am doing coursera online course on Bitcoin and Cryptocurrency Technologies. It defines the concept of hash pointer in the first lecture as pointer to where some information is store and ...
9
votes
3answers
12k views

ECDSA Signature and the “z” value

The following link contains details on how to reverse the ECDSA signature if given two identical "R" values. http://www.nilsschneider.net/2013/01/28/recovering-bitcoin-private-keys.html I have read ...
9
votes
1answer
1k views

Why does Bitcoin use two rounds of SHA256?

Each blocked is hashed twice. Why isn't one application of SHA256 enough?
9
votes
9answers
2k views

What is a good analogy (which a layperson would understand) for the process of Bitcoin mining?

I will be explaining Bitcoin to a non-technical group and I am hoping somebody can provide me with a very basic visual analogy of the crypto-currency mining process. My half-baked idea, was to ...
9
votes
1answer
502 views

When a transaction is broadcast to the network, what is actually being sent?

When a transaction is broadcasted to the network, what is being sent? Is it a hash? if yes, is it going to be the hash of: previous transaction + public key of the receiver?
9
votes
2answers
3k views

Where did the idea of blockchain come from? Git was already using it since 2005

With bitcoin's blockchain, each block's hash is computed with the previous block's hash. That makes all blocks an immutable chain. This is not the first time people used a hash-chain. As far as I ...
9
votes
3answers
7k views

Relation between Network Hash-Rate & bitcoin value?

how is the relation betweeen network hash rate to healthyness of bitcoin, such as bitcoin value compared to USD, or the growth rate of this currency?
9
votes
1answer
2k views

What complexity class is Bitcoin's proof-of-work (hashcash) in?

To formulate this question precisely, I will define an idealized hypothetical "perfect" hash function H(n) which has nice scalability properties, and will formulate a problem PERFECT HASHCASH in terms ...
8
votes
3answers
2k views

If SHA256 were compromised tomorrow, would Bitcoin collapse, or is there some contingency plan to move the network to a new hashing algorithm?

Hashing algorithms have a long history of becoming widespread and then declared insecure - MD5 is a good example. As Bitcoin increases ever more in popularity, and cryptanalysis becomes ever more ...
8
votes
3answers
8k views

How to calculate a hash of a Tx?

How does one calculate the hash of a Tx? Which fields need to be double SHA hashed and in what order?
7
votes
4answers
501 views

How is it possible that transactions can be added to a block currently being mined?

It seems counter-intuitive that the current block can be hashed and transactions can be added to it, however that is what this thread indicates. Can someone help me connect the dots (not necessarily ...
7
votes
2answers
1k views

What would happen if two blocks had the same hash?

Consider the following scenario: January 2016 block A gets submitted. Its hash is 0001010. January 2017 block B gets submitted. Its hash is also 0001010 (collision). 10 minutes later, block C gets ...
7
votes
2answers
572 views

Possible to create a double spend attack by replacing a Tx in the merkle tree?

This question on crypto.SE describes how preimage attacks are avoided in the Bitcoin network. For a second preimage attack: hash(x) = hash(y) implies hash(hash(x)) = hash(hash(y)) So it ...
7
votes
1answer
8k views

Are Bitcoin ASICs good for anything else other than mining? [duplicate]

If I purchase an ASIC (hypothetically) and then for whatever reason Bitcoin disappears, becomes defunct or otherwise, is there anything else I could possibly use it for, such as SHA256 cracking - or ...
7
votes
1answer
3k views

Can an SHA256 hash be used as an ECDSA private key?

Is it possible to map a pass-phrase directly to a Bitcoin private key by using its SHA256 hash? I remember reading somewhere that not all 256 bit values are valid ECDSA private keys. If so, how can I ...
7
votes
1answer
521 views

Is Quark as secure as SHA 256?

I'm trying to make certain I'm understanding the purpose behind the Quark algorithm. There are lots of devices that need secure algorithms but have severe power and processing constraints such as ...
7
votes
1answer
3k views

How does a miner perform hashing?

I'm trying to walk my way through the process by which a miner hashes. Let's say the getwork request returns a data field of: ...
7
votes
1answer
1k views

How to 'attach' metadata to a bitcoin receive address

I need to generate a receive address that is directly associated with some metadata, M, that forms part of a verifiable contract. I require that customers can verify that an address really was ...
6
votes
1answer
4k views

How is a block header hash compared to the target (bits)?

I'm trying to wrap my head around the mining process by doing a small example of block hashing. According to the Wiki entry about difficulty, the target for a block hash can be read from the "bits" ...
6
votes
3answers
1k views

Does every nonce really have an equal chance of winning?

I set out to test the claim: "Every nonce has an equal chance of winning." Time Evolution So, I plotted, with gnuplot, the nonce values vs. hashes for all the valid blocks in the blockchain:(Also, ...