People who have been following my discussions about the new “multiverse consensus” with Serguei Popov have most probably realized, that most of the discussions concerned the way how mana is calculated.
The basic idea of the “multiverse consensus” is, to put the votes on the tangle (as part of the transactions) and allow nodes to reach consensus by passively observing the statements of others. This would allow us to reach consensus without having to exchange any additional vote messages. For this to work, nodes however need to have consensus on mana (everybody needs to “read” the tangle in the same way to come to the same conclusions).
My initial idea was to use something like the “rank” of a transaction (its distance from genesis) to calculate the mana vector. Since the rank of a transaction is defined by its position in the tangle, everybody would calculate the same mana vector and we would have absolute consensus on mana.
Serguei however pointed out that the rank is “gameable”. An attacker could issue a long chain of transactions that would modify the “perception of time” and allow attackers to gain more mana than the other honest nodes in the network (remember: mana = coins * timeHeld [simplified]).
He therefore favors to use the “local clock” of nodes to calculate the mana vector because this is not “attackable” by gaming the structure of the tangle. Honest nodes who have their time set correctly, will already have “more or less consensus” on the current time without any additional voting.
While I agree to this point and using the “more or less consensus” on time that we get “for free” as a foundation for mana seems to make sense it still has some issues. Nodes that newly join the network or that have been offline for a prolonged period of time will have completely different perceptions of mana than nodes that have seen the transactions “in time” (because they see them only after they have solidified the missing transactions).
I now want to propose a mechanism that combines both of our “ideas” into a single solution that combines the best of both worlds (using local time + reaching absolute consensus on mana - even for nodes that are offline and see the transactions later):
- Every node includes a timestamp in his transaction that defines when this transaction claims to be issued.
- The timestamp of a transaction needs to be bigger than the timestamps of both of its referenced transactions.
- Nodes only use transactions in their tip selection algorithm that have their timestamp set to a value that is smaller than their local time.
- The mana gets calculated by using the timestamps in the transactions - but they only consider transactions that again have their timestamp set to a value that is smaller than their local time.
Since nodes can lie about the timestamp in the transaction there are essentially three things a node can do:
- It can be honest which is perfectly fine.
- It can set the timestamp to be “in the future”, which would increase its mana gains compared to the honest nodes, but since none of the honest nodes will consider the transaction either in their tip selection or in their mana calculations until the transactions “time has come” these gains are essentially meaningless and are equivalent to just issuing the transaction at the claimed time.
- It can set the timestamp to be “in the past”: This will cause the transaction to be picked up immediately but the node will artificially decrease the mana that it receives. Since consensus is based on the votes a transaction receives, this artificially lower timestamp will not mess with consensus and just lower the mana an attacker receives.
This essentially means, that both “directions of lying” will be punished:
- timestamp too far in the future: nodes ignore the tx until the “time has come”
- timestamp too far in the past: no influence on consensus but the attacker receives less mana
Conclusion
This approach not only creates an incentive for nodes to be honest when assigning their timestamps, but it also creates an objective way to calculate the mana that is directly related to “human time” and that is not gameable by building certain structures in the tangle.