Economic Clustering

Hi guys,

this thread is supposed to gather reviews for an implementation concept of Economic Clustering. Its purpose is to protect PoS systems as they suffer from the Nothing At Stake problem at defined here: Re: Proof of stake instead of proof of work

If reviews successfully provide insights about the correctitude and flaws can be removed from the concept, I have great hope that Economic Clustering is going to benefit all the Peercoin community, the Nxt community and all other PoS communities. Implementation in either PoS coin should be easy. I hope this thread fits the board’s regulations. BCT moderators are not that open to new concepts.

[i]source https://nxtforum.org/news-and-announcements/economic-clustering/[/i]

[quote=“Come-from-Beyond, post:8, topic:2425”]I’d like to announce a new feature. Today I committed code related to Economic Clustering (EC). This concept is a development of the idea of Economic Majority introduced by Meni Rosenfeld.

In his notes BCNext states that EC solves the most critical flaw of Proof-of-Stake concept, according to the description this flaw is what others call “Nothing-at-Stake” problem. The 3rd part of the Plan contains such the words:

Mining in Nxt relies on cooperation of people and even forces it
That was said about EC.

The concept of economic clustering is quite simple. Words “economic majority” say enough to explain how it works. From technical point of view it means that if someone decides to rewrite the history of the blockchain he won’t be able to include transactions of those who don’t take part in the attack, because every transaction contains the id of one of the recent blocks. When Alice sends money to Bob in exchange for something she’ll get what she wants only if Bob validates the transaction. And this can happen only if they are both on the same branch.

Forgers can’t forge all branches at once, they are faced with a choice, an attempt to forge more than one branch will lead to their exclusion from one of the clusters.

The proposed technical solution will also be used for analysis of transactions to detect forks. This is one of the reasons why I decided to implement part of EC without waiting for complete TF. Another reason is that proposed solution should be peer reviewed. Recent hot debates on BitcoinTalk regarding Nothing-at-Stake show that people are paying a lot of attention to PoS cryptocoins. This is a good opportunity to get a lot of reviews.

Extra consensus rule mentioned in the 1st part of the Plan is a rule that defines choice of an economic cluster a node sticks too. I can’t reveal all the details yet, we still need to build infrastructure of nodes and hubs and (this is more important) to form such a cluster…[/quote]

[i]source https://nxtforum.org/general-discussion/on-economic-clusters-and-the-longest-chain/[/i]

[quote=“Come-from-Beyond, post:120, topic:2353”][size=8pt](Based on BCNext’s notes and our discussions, TLDR version)[/size]

The rule of distributed consensus in Bitcoin is quite simple - the longest chain wins. By saying “longest” we mean one with the highest cumulative difficulty. Majority of bitcoiners are geeks and such “mathematical” approach is very appealing to them.

Bitcoin Fork that happened in March 2013 clearly showed that the longest chain rule is not enough. This rule doesn’t work in extraordinary situations, but we don’t have two Bitcoin branches so what fixed that problem? Some might argue that Bitcoin is centralized and Bitcoin users follow orders of Bitcoin devs, but BCNext thinks that the correct answer is “Economic Majority”. This term was coined by Meni Rosenfeld. In plain English it means that majority of users decided to abandon one of the branches and stick together even by violating the Rule.

BCNext decided to use this phenomenon to resolve extraordinary problems happening in Nxt. Nodes accept freshly forged blocks according to the longest chain rule, but when something happens they follow the economic majority. Economic laws can’t be ignored (history of Soviet Union proves that), by respecting these laws we actually make Nxt stronger.

Let’s conduct a thought experiment. Imagine that network splitted for 24 hours and there are 2 competing branches. Thousands transactions are processed, thousands goods are delivered to the buyers. Now the network is merged and we see that the longest chain contains only 30% of the transactions but the shortest the rest 70%. Which network will win? BCNext thinks that the shortest one, coz economic majority will decide to lose less than more (we assume that loss is proportional to number of rolled back transactions), and I tend to agree with him. The reader is free to have another opinion of coz.

Another experiment. 20% of Bitcoin economy that owns 65% of hashing power decided to fork Bitcoin and add unlimited supply of the coins. Let’s assume that they would mine 25 BTC per block forever. There are no other differences. What blockchain will a new user download? Of coz the one with unlimited supply because “the longest chain wins”. Will the user agree on that? I doubt he will chose 20% of economy instead of 80%. And again we see that economic laws are more important than “mathematical” ones.

Nxt uses economic laws to help a node to choose among thousands branches. In some cases this is supposed to happen automatically. For example, if Alice and Walmart are on different branches then she can’t buy anything coz Walmart won’t see her transaction. The things are more complicated for Walmart, it have to invest into servers or rely on other market participants. If a new user joins Nxt and there are several blockchains he should just ask friends, who brought him there, what blockchain to download (hash of a recent block is enough).

If one knows accounts of “big” market players he can analyze the blockchain to make sure that he keeps sticking to the majority.

PS: Well, I hope I didn’t forget anything important. I’ll add it if I did.

Edit: Looks like I made it confusing when said to ask a friend. This is required only for new users who don’t want to enter accounts of thousands market players. “Ask a friend” trick should be used only once, after that software will collect all necessary accounts according to economic activity of the user. It’s still possible to enter 10 accounts of “big” market players like Walmart if u don’t have friends. :)[/quote]

If one knows accounts of "big" market players he can analyze the blockchain to make sure that he keeps sticking to the majority.

What is the incentive for big market players to make their accounts public? Wouldn’t they lose a lot of privacy by doing this?

source PM

Big players == companies. They don’t need privacy. Actually, they need transparency coz otherwise the state won’t allow them to use Nxt.[/quote]

Hi,

  • How coin can “enter” selected cluster?
  • What prevents me from spending on more than one cluster?
    • Why one cluster will exclude ambiguous transactions and lose fees?
  • Can my tx be invalidated by having too old(ambiguous) “inner checkpoint”?

Thanks
P.

Thank you for replying.

Could paraphrase that?

Nothing.

It is part of the protocol. They will have to exclude them.

The age of the inner checkpoint will naturally be limited by the expiration period of the transaction itself.

Anyway, the majority is interested in protecting the blockchain (that is an assumption), so they will only include younger inner checkpoints. On the other hand side, they will only include such inner checkpoints of those branches they are sure of that will win. The current idea is to set this to 600 seconds but could be revised based on statistical data.

More reviews, please. :beer:

(Your smileys are cool. :whistle: )

Could paraphrase that?[/quote]
Say I have one UTXO now, not tied to any cluster, I’ll send it with marks from 3 clusters:

  • my output will be marked as DoS ? Will it be destroyed, blocked?
  • which cluster will take it?

It is part of the protocol. They will have to exclude them.[/quote]
We’re talking about 2 or more competing clusters, all of them “think” that they are “the right one”, I don’t see how protocol can enforce self punishment.

The age of the inner checkpoint will naturally be limited by the expiration period of the transaction itself.
I'm not familiar with tx expiration period. That creates considerable limits on offline transactions and contracts.

After successful attack not only attacker can double spend but all users?

I’m not convinced to this solution, trust, public entities, expiring txs. Much easier to simply ask Wallmart which fork is good one, if they accept my money for goods - I need no other proof. After 100 blocks update local checkpoint, be in ‘sync’ with WM, joy shopping.

[quote=“kac-, post:6, topic:2442”]Say I have one UTXO now, not tied to any cluster, I’ll send it with marks from 3 clusters:

  • my output will be marked as DoS ? Will it be destroyed, blocked?
  • which cluster will take it?[/quote]

No. No.
Clusters do not interact with each other. The will take what they can (transactions belonging to them).

2 or more clusters are an anomaly. It is like the Bitcoin fork 2013. They are like having two different coins without new software.

Expiration is to resend transactions with higher fee if not included in time.

Could you describe such attack with specific details?

I cannot follow here. Transactions are tied to clusters. Double-spending is therefore only possible if multiple versions of transactions exists for different clusters. But as stated above, economic majority will assume that there is one cluster only. So, they will not sign it for two.

Maybe, it would help if you consider the fact that Economic Clustering only contributes to consensus if PoS fails. It is an addition, no replacement. Furthermore, it is not necessary to know how to reach big players and Walmart is not enough.

I have a problem with this… newspeak :slight_smile:

  • forging → mining
  • clusters → forks
Expiration is to resend transactions with higher fee if not included in time.
Can I set expiration time to +∞?
Could you describe such attack with specific details?
If all txs have embed checkpoints when network decide to switch working chain all transactions with fresh checkpoint will be removed from history. Is this checkpoint an option or standard?
But as stated above, economic majority will assume that there is one cluster only. So, they will not sign it for two.
Economic majority overcomes PoS rules here, miner is practically forced to mine only one fork - chosen by economic majority. I have no problem with such model in PoW environment. But with PoS you expect to have part of decision power proportional to your holdings, whether it was acquired 1 or 10 years ago, in different market or political environment and with different than actual majority expectations. Will NXT be fine with multiple forks because it's quite clear that white/blacklisting is trivial and inevitable with EC? It's more complicated than I thought. I know that we need some kind of consensus but this one is controversial imo.

[quote=“kac-, post:8, topic:2442”]I have a problem with this… newspeak :slight_smile:

  • forging → mining
  • clusters → forks[/quote]

Seems legit. Clusters force the adoption of a specific fork.

No. I do not think so. If I understand the current implementation correctly, 22 days are the upper limit.

Was that the attack or do you still need more data?

It should be standard to keep the cluster together but transactions without inner checkpoint are allowed as well.

[quote=“kac-, post:8, topic:2442”]Economic majority overcomes PoS rules here, miner is practically forced to mine only one fork - chosen by economic majority.
I have no problem with such model in PoW environment. But with PoS you expect to have part of decision power proportional to your holdings, whether it was acquired 1 or 10 years ago, in different market or political environment and with different than actual majority expectations.[/quote]

That is the idea. They are forced to do what is good for the cluster aka the global economy. As far as I know there is only one global economy now.

Clusters cannot interact with each other. So, if “they think”, they should split why not. If they want to merge in the end, one of the forks have to be abandoned anyway. So, they should think twice before they split.

So, the ultimate goal for a consensus rule of EC goes like this: create a cluster that is the mightiest and the hardest to escape. It should absorb new people fast and recklessly.

Could you formulate such rule for EC?

:cry: :)) :omg: (These smileys. :smiley: )

That is the idea. They are forced to do what is good for the cluster aka the global economy. As far as I know there is only one global economy now.
Aren't we all here because mainstream trends failing? Who better than distributed ledger shareholders decide what is good for their share value(strictly correlated with the growth of economy ledger serves) and network healthy? Why to own stake when you don't have control? Majority of users can be manipulated or forced, tend to don't care, abuse, act irrational due to race/religion/history. I see EC more as disintegration mechanism rather than cement.

Since when do companies not need privacy? If they have to reveal their accounts in public then they are not going to use the currency. And a state forcing them to is never going to happen.

I believe u can’t pay to Walmart without knowing its account. Define “privacy”, plz.

I believe u can't pay to Walmart without knowing its account. Define "privacy", plz.

My interpretation of that comment is that Walmart would not want to use Bitcoin addresses, today, because doing so would mean that you could figure out a couple of them, and then use blockchain forensics to identify where all of those feeder accounts have their coins moved to, and eventually determine a likely set of addresses that are the “main” ones that Walmart uses.

I believe u can’t pay to Walmart without knowing its account. Define “privacy”, plz.[/quote]

I could have phrased that better, Ben explained it better than me. I mean isn’t there a difference between (a) Walmart giving an address to a customer for a sale, and (b) Walmart revealing their entire accounts for live viewing on the blockchain.

And wouldn’t (b) be required in an economic cluster?

I interpret river333’s statement like this: Walmart would want to publish their address, but not the content of this address to the public. It is like public keys and private messages using these keys.

I discussed this with CfB already. He asked if in Germany there are not any law to supervise companies. There are but a company still can hide things before the public and especially before the competition. There are public balances but they are updated only once a year or so.

So, his point was that you cannot hide anything on a blockchain. The only solution here, I said, would be Zero-Knowledge-Proofs and Indistinguishability Obfuscators. But we are far from usable solutions there.

[quote=“river333, post:14, topic:2442”]I could have phrased that better, Ben explained it better than me. I mean isn’t there a difference between (a) Walmart giving an address to a customer for a sale, and (b) Walmart revealing their entire accounts for live viewing on the blockchain.

And wouldn’t (b) be required in an economic cluster?[/quote]

Nxt doesn’t have anonymization service. I’m afraid if companies must hide their money flows then they can’t use Nxt.

[quote=“ChuckOne, post:15, topic:2442”]I interpret river333’s statement like this: Walmart would want to publish their address, but not the content of this address to the public. It is like public keys and private messages using these keys.

I discussed this with CfB already. He asked if in Germany there are not any law to supervise companies. There are but a company still can hide things before the public and especially before the competition. There are public balances but they are updated only once a year or so.

So, his point was that you cannot hide anything on a blockchain. The only solution here, I said, would be Zero-Knowledge-Proofs and Indistinguishability Obfuscators. But we are far from usable solutions there.[/quote]

Thanks, that answers my question. There are many legitimate reasons a company needs privacy, so I think this system would discourage many from using Nxt.

But we r waiting for ZeroCash to “borrow” their anonymization tech, so things r not so bad as they look. ;D
If we get an anonymization service then we will use another way to “mark” blockchains belonging to the economic cluster. A special transaction type that doesn’t allow to track real accounts with the coins should be enough.

But we r waiting for ZeroCash to “borrow” their anonymization tech, so things r not so bad as they look. ;D
If we get an anonymization service then we will use another way to “mark” blockchains belonging to the economic cluster. A special transaction type that doesn’t allow to track real accounts with the coins should be enough.[/quote]
Interesting approach from the dev of initially closed source project :slight_smile: Anyway, still contrary to EC public cashflows.
One question: I see that you want to embed few (as much as possible?) services into network core, why do you think that embedding them is better than allowing multiple services to develop, compete and evolve around your network?

We definitely have different definitions of “Economic Cluster”. The proposed approach perfectly fits into EC concept IMO.

Btw, “closed source” is just an urban legend. Java binaries were never obfuscated, any disassembler would generate an almost 100% copy of the source code (there was such a copy somewhere on GitHub). “Closed source” trick was used to put Nxt under radar of majority of Bitcoin millionaires who would try to kill Nxt in its infancy (later they tried to do it but failed).

Nxt is a platform, easily extendable platform. If we can embed everything then why not?