How to start the blockchain on a desert island

If you ever find yourself on a desert island, you can find useful knowledge about how to manage the process of decentralized consensus, or in other words, control is very simple bloccano manually. All you need is a few survivors guys, this post pen and a couple Liskov paper.

If you are not sure what this skill is useful for your survival, make sure to read the post about how the blockchain can significantly improve life on the island.

Let’s go back to the original story and go all the way with our fearless heroes who crashed and was stranded on a desert island somewhere in the South Pacific ocean — Hugo, Sawyer, Kate and Jack.

Brief overview: a group of guys trying to implement IslandCoin — the revolutionary new currency, which would end destroyed the economy of barter island. All agreed that would be fair, if initially everyone will have 100 coins. Because they have no metal for minting coins, they should make them with a few sheets of paper. Faced with the problem of trust, the group was unable to agree on the fact that one person followed the remains. Their only option is to maintain the balance all together.

We’ll start with the fact that our use case on the island, is probably the most simple implementation of the blockchain. In future posts we can explore other implementations and bind them to such concepts as “Proof of Work” and “Proof of Stake”, which will help us to see their advantages and disadvantages. But let’s start as easy as it happens.

What are we trying to achieve? In fact, everything is very simple — we attempt to maintain a simple table of balance sheets on a sheet of paper. This table shows how many coins each of our heroes. The trick is that we will not have a single sheet of paper, which served as the source of truth — we need to they were all the same, at the same time to allow everyone in the team to support their own version is a decentralized part. And, of course, we hope that all 4 sheets of paper will ultimately show the same thing — this is the consensual part.

So will look like this sheet of paper?

Day 1.

Hugo is now 100 coins

from Sawyer 100 coins

cate 100 coins

Jack 100 coins.

 

Signed Hugo, signed by Sawyer, Kate signed, signed Jack.

This sheet is the first with which everyone agrees, so he was designated as day 1. Where did these balances? Earlier we agreed that would be fair if everyone will initially be 100 coins. We will also need one of the survivors to write this paper. In fact, no matter who, let’s take Hugo. He will publish this paper for everyone and make sure everyone has kept a copy (on the island there is an amazing copier, which I forgot to mention).

Since it is expected that the balance of the coins will change, we will create an updated sheet at the end of each day. Perhaps not always, Hugo will publish updates — we want everything to be as honest as possible.

Another important part: because of the lack of mutual trust everyone in the group confirms the status update individually. This can be achieved in a simple manner, if each of the survivors will have to sign every document, but only if they agree with what is written in it.

How many people should sign the document to be considered final and approved? We need to reach consensus, so the sign needs most. Since we have only 4 people, most of them at least 3 out of 4. Paper, given above, was signed by all four, so she definitely final. Why we do not require all four signatures on the paperwork? Because it will allow one person to endanger the whole process. If Sawyer will go fishing for a few days, the team will not be able to update balances, until he comes back — it gives one person too much power. Why do we need most? Why not 2 of 4 signatures? Because if we require only 2 of 4, we can eventually get a situation where two people (for example, Hugo and Sawyer) will sign one version of the balance, and the other 2 people (Kate and Jack) will sign a different version that does not match the first. We can’t get two contradictory versions, which are considered final.

The morning of the second day Kate wants to buy a tomato. Hugo sells tomatoes for 2 coins a piece. She wants to send 2 coins Hugo. Kate takes a new sheet of paper and writes down the translation of it:

Kate step 1: translation 2 coins Hugo — signed by Kate

This is the first action Kate, so she called him. In addition, Kate signed the document. We must have her signature, so that no one could fake a transfer from her account.

Approaching the end of the second day, and the team wants to publish an updated set of balances. Hugo published a document on the first day and collected all the signatures. It makes sense to do it at a time. The team agrees to use a simple rotational order: Hugo, Sawyer, Kate, Jack, Hugo, Sawyer, etc. This means that for the promulgation of a document on the status on the second day those responsible will be Sawyer. In its document reflects the transfer Kate:

Day 2.

Kate step 1: translation 2 coins Hugo — signed by Kate

Now Hugo is now 102 coins

from Sawyer 100 coins

Kate has 98 coins

Jack 100 coins.

Signed By Sawyer.

This document, which made Sawyer, not yet final, because it is signed only by Sawyer. He needs to collect more signatures. Sawyer goes through the team and asks each to check (verify) and sign it. This document is very easy to check. First, the verifier should look into their documents paper status, which shows the balances for the previous day (in this case day 1). Next, the verifier needs to see the new list of transactions. In this case we have only a translation of Kate. This transaction is easy to check: we can verify that it really is signed by Kate, and we can make sure that Kate does have coins on its balance sheet to pay this amount Hugo.

When every resident of the island completes the verification process and signed the paper, Sawyer now Sawyer at the hands of the final document for the second day to make it public for all. All make up and go to bed happy and satisfied.

Day 2.

Kate step 1: translation 2 coins Hugo — signed by Kate

Now Hugo 102 coins

from Sawyer 100 coins

Kate has 98 coins

Jack 100 coins.

Signed Hugo, signed by Sawyer, Kate signed, signed Jack.

The day comes 3. The system works well, and all happy to spend their coins. Hugo wants to buy firewood from Sawyer for 10 coins. Sawyer wants to get the pills from Jack for 25 coins, and Jack is hungry and wants to pay 2 coins for Hugo to buy a tomato. Each of them creates a sheet of paper, detailing their transfer:

Hugo step 1: transfer 10 coins Sawyer signed Hugo

Sawyer step 1: translation of 25 coins Jack — signed by Sawyer

Jack step 1: translation 2 coins Hugo -signed by Jack.

The approaching evening. Current balances publishes Kate. To be sure that Kate will include these translations in its offer document, each of them must provide a copy of its order to transfer. In fact, it makes sense to give copies to everyone because the person who wants to translate, do not have to remember whose turn it is today to publish an update. Jack is late with the transfer of copies of his instructions to Kate, and by the time he brings it up, the balance of the day is already written:

Day 3.

Hugo step 1: transfer 10 coins Sawyer signed Hugo

Sawyer step 1: translation of 25 coins Jack — signed by Sawyer

Now Hugo 92 coins

Sawyer has 85 coins

Kate has 98 coins

Jack 125 coins.

Signed Kate.

Jack is disappointed that this balance does not include transfer. This means that Hugo will not get paid Jack for tomato and not give Jack a tomato for dinner. Today, Jack is going to bed hungry. He is angry goes to look for something else to eat, and would not sign the proposed document Kate for the day. Fortunately, Kate can get enough signatures from the rest of the team members:

Day 3.

Hugo step 1: transfer 10 coins Sawyer signed Hugo

Sawyer step 1: translation of 25 coins Jack — signed by Sawyer

Now Hugo 92 coins

Sawyer has 85 coins

Kate has 98 coins

Jack 125 coins.

Signed Kate, Sawyer signed signed Hugo.

Kate has received 3 signatures on the document, each of which confirms that the balances do correspond to translations, and yesterday’s balances. We have the majority, so this status sheet shall be deemed final.

Day 4, and no one knows where Jack is. He was fishing yesterday, caught in a storm and never returned to camp. This can be a problem, because today it is the turn of Jack to publish an update of the balance. Kate wants to make a couple of payments today, she writes them on a sheet of paper and gives a copy to all:

Kate’s step 2: transfer 10 coins Sawyer — signed by Kate

Kate’s step 3: translation of 2 coins Hugo — signed by Kate

Approaching the evening, and Jack’s still not back. As discussed earlier, today the turn of Jack to publish balance sheets, but it is nowhere to be found, so the update of balance on this day is missed.

Day 5, and today Hugo is in charge of publishing daily updates. Some days it rained, and Hugo wants to sleep it was warmer. He asks Sawyer to build him a small wooden hut. Sawyer wants 200 coins for the work. This is a problem for Hugo because he’s only got 92 coins. Hugo appears a crazy idea: he is the one who publishes the balance today, why not add crazy Shuttle this amount, Sawyer anyway?

Hugo step 2: translation 200 coins Sawyer signed Hugo

Today there are other translations. Hugo is the transfer of Kate from yesterday, and the transfer of Jack from the day before, which was not produced. He puts it all together with her new crazy translation:

Day 5 (day 4 skipped).

Kate’s step 2: transfer 10 coins Sawyer — signed by Kate

Kate’s step 3: translation of 2 coins Hugo — signed by Kate

Hugo step 2: translation 200 coins Sawyer signed Hugo

Jack step 1: translation 2 coins Hugo -signed by Jack.

Now Hugo 0 coins

from Sawyer 295 coins

Kate 86 coins

Jack 123 coins.

Signed Hugo.

Hugo signs this upgrade, although the transfer does not actually make sense. To do this status update final, he needs to collect 2 signatures. When it comes to Sawyer and Kate, they notice that the previous final balance (3 days) Hugo was 92 coins. How could he send 200 coins Sawyer? They refuse to sign the balance, yet he does not correct this mistake and remove this invalid transfer. Hugo reluctantly agrees and publishes a new balance, which is correct. They eventually sign it:

Day 5 (day 4 skipped).

Kate’s step 2: transfer 10 coins Sawyer — signed by Kate

Kate’s step 3: translation of 2 coins Hugo — signed by Kate

Jack step 1: translation 2 coins Hugo -signed by Jack.

Now Hugo 96 coins

Sawyer has 95 coins

Kate 86 coins

Jack 123 coins.

Signed Hugo signed cate, signed by Sawyer.

This update is a final balance, since it contains 3 signatures.

In the morning of day 6, Jack finally returned to the camp. He had a rough couple of days with the storm and other troubles. He was not involved in the discussions over the past two days and missed the announcement about the new transfers and the publication of new balance updates. He really doesn’t know how many coins he has. He asks the first survivor, whom he met to give him the latest updates that he missed. He gave a final update on the 5-th day and approved the update Kate, published in the 3rd day.

For Jack can be easily synchronized with the rest of the group. It can make sure that these balance updates have been signed at least 3 times, so it can be relatively calm, they’re fine. It can also perform calculations independently on the basis of these updates, and the latest updates, which he has (second day). This will allow Jack to participate in today’s transfers like he didn’t miss anything.

The system works well. However, it is a bit simplified, but enough for the needs of island residents. And of course, we can’t be functional blockchain without White rare! The team sits down and celebrates achievement, publishing this remarkable document:

Island Coin White Paper

Why this can be considered bloccano? First, each sheet of paper, issued daily, is a block. Each block is numbered and indicates the previous, forming a block chain. To check the current state of the remains, any observer should start with the beginning of the chain (day 1 – Genesis-unit) and test each of the blocks one by one in a row. Balances are built one after the other.

This is a perfect implementation of the blockchain? Maybe not. It can largely be improved. For example, he serves only those four people. What happens if someone else wrecked on the island? Whether this Protocol is suitable to them? In addition, currently, this Protocol is exclusive; how can we make it inclusive? What if we want to change it, using a Proof of Work or perhaps Proof of Stake?

We consider these ideas in the next article in this series.

Source

Share link:

  • More