Теперь Кью работает в режиме чтения

Мы сохранили весь контент, но добавить что-то новое уже нельзя

What is blockchain technology?

ТехнологииBlockchainDecenter
Steve Fei
  · 672
DeCenter expert  · 3 нояб 2017

Blockchain technology is fairly easy to understand, but you need to first have a grasp of some basic terminology. For example, you have to understand what "hashing" means.

Hash - this is an encryption algorithm: it takes a text, a picture, or a file and then generates a string of symbols (numbers and letters) associated with it. The same files will always end up generating the same hash. Different files will ideally always generate different hashes, but sometimes there are coincidences and the same hash is generated for differing files. This is one of the weaknesses of this encryption algorithm.

For example, I could write a message saying "Hello world," and I want to send it to my friend. But I have to check if it got to my friend in the right form, so in the form that I sent it in. You could ask to see the sent message and compare it to the one you meant to send. But this is not always a rational thing to do, for example, if your message also has an HD video and takes up a lot of memory. So to make sure your message did not change as you sent it, you use hash. If your sent message has the same hash as the received message, that means your message has not been changed.

Let's try to hash a message. Enter the words "sha-256 online" into Google. Click one of the hash calculator links Google offers you (sha-256 is one of the hashing algorithms).=

For example, the hash from the phrase Hello world looks like this:

64ec88ca00b268e5ba1a35678a1b5316d212f4f366b2477232534a8aeca37f3c

And below we have a hash from the phrase hello world, with only lowercase letters:

b94d27b9934d3e08a52e52d7da7dabfac484efe37a5380ee9088f7ace2efcde9

There's no overlap!

You can experiment with any words and phrases. You will always get the same hash for the same words, and differing hashes for differing words.

So now we understand hash. Let's move on to the concept  of "blockchain."

Blockchain is a string of encrypted blocks of code that are connected to one another.

Let's create our own blockchain. You can put anything you want in it, but for the sake of this simple exercise let's write down money transactions.

The first block will contain the following information:

Anna → Bob :: 10 dollars

Bob →  Alice :: 20 dollars

Anna → Alex :: 30 dollars

You can write down this in information in your Notebook app and save it as a file titled 1.txt.
The first block in a blockchain of cryptocurrency is called a Gensis block, and it is written out by hand.

Copy the information from the first block, and go back to the website we used for the phrase Hello world. Now enter the three lines of information into the website and generate a hash. This is what we get:

169481005b3571466ade171fa9239a898ab54e782158c8beb7cf580eaeeb0e12

Now let's create a new file called 2.txt and write down a few more transactions, and in the last line enter the result of your hashing of the previous file. Like this:

Tammy→ Paul :: 50 dollars

Julian → Kate :: 20 dollars

169481005b3571466ade171fa9239a898ab54e782158c8beb7cf580eaeeb0e12

Save this, and calculate the hash for this entry. You get the information about transactions + the previous hash:

70823a45a1fef27129b0e678f8cd18ac8fd88111002fc5a414cfe6a9c7bc5e94

Now do the same thing with a third file, and so on. Do this with all the subsequent files. You can make as many as you want. And a collection of such files allows you to understand what the simple idea of "blockchain" actually entails.

Interesting. So it's basically the encoding of a sequence of transactions. Why is it better and increasingly being... Читать дальше