You may have heard the term hash or SHA-256 , but what do they actually mean ?
In order to decide which block of transactions will be entered next to the blockchain some sort of contest is held between the miners. They all get a riddle to solve, but you can’t actually solve this riddle logically – you have to guess the answer.
Imagine that you are a Bitcoin miner, and each time you want to enter your block into the blockchain and get a reward you would be given a combination lock and would need to guess the combination in order to enter your block.
Now let’s say that your computing power or hash/rate is the number of combinations you can guess in a second. So the more computing power you have the faster you’d guess the combination.
Since the Bitcoin network wants to keep the time between blocks created in the blockchain constant, as more miners or computing power are added to the network it will become harder to guess the combination. Just imagine that as more and more people try to guess the combination you will be given locks with more possible combinations.
A hash is just a method used to guess the combination for the lock. It’s used by turning a random large number into a smaller number by taking certain actions. so for example – let’s say that each time you guess the lock’s combination you would randomly pick a large number and take the first, middle and last numbers from it. If this doesn’t work you will randomly pick a different large number and guess again.
Of course the miner’s’ calculations are much more complex but the idea is that you decide on a certain method of action for guessing and execute it until you get the answer.
The SHA-256 or “secure hash algorithm 256”, is just a specific way of hashing. The same way we could have named our previous example for hashing the “99Bitcoins hashing method”.
Using hashing helps the the Bitcoin network stay immuned to alteration and fraud – but more about that in a later video.
Is it just me of does this actually resemble hacking? I might have got this all wrong, but it seems that you have to guess a big block of numbers to “break into” that blockchain. Am I right, Ofir?
hmmm…well I’m no hacker so I can’t really answer that but it may resemble some sort of DDoS attack maybe..
“Hacking” may imply work that is done to circumvent the design of a system, which this is not. I like to think of proof-of-work as a computational hurdle which is outsourced to a network of independent participants. The lock described in the video is more akin to a set amount of work that the network has decided is sufficient for broadcasting a new block, given the amount of time it took previous blocks to be found. The goal of the network is to constrain block creation to a constant rate – which is central to Bitcoin’s scarcity.
Great video, Ofir! Thanks a lot!
I wonder what other types of HASH there are besides SHA-256? And what are the differences between this Hash and other ones? Thanks!
You can check this out on Wikipedia https://en.wikipedia.org/wiki/SHA-2
Thank you for doing a video explanation of what this means. I still am not 100% sure I understand but I do get the basics of how this works. I am very new to bitcoins and I have a LOT to learn so thanks for what you are doing on this site!
You are welcome
Do you somehow have an advantage if you have a more powerful computer to do the mining with?
Yes, that is what is known as a Hash Rate – more powerful computers solve the “lock combination” quicker – take a look at the video again it will probably make more sense.
I have a friend that is into bitcoins and he constantly talks about things like Bitstamp, Coinbase and Bitcoin Hash, so I am a little used to these terms but always wondered what they meant. He tried explaining all these to me but he is quite advanced at this, while I’m just starting. I started reading your bitcoin “how to” guides and I feel I am finally getting somewhere. Thank you!
Thanks for the feedback! You’re welcome