Oracle Platform
Oracle Platform
Alexander Herrmann
No Institute Given
Abstract. Decentralized applications (Dapps) and Decentralized Autonomous Organizations (DAOs) executed via smart contracts on blockchains
are starting to build a growing ecosystem. Many of these Dapps and
DAOs have an urgent need for a very reliable information feed connecting the blockchain ecosystem with traditional centralized services and
information. The Oracle-platform will be an open source platform, which
Dapps and DAOs can utilize to build a state of the art reliable information feed for their services. Using verifiable hosting environments and a
split game theory enforced with smart contracts, this Oracle-platform
will be outstanding in terms of security and reliability.
Keywords: DAO, decentralized price feeds, Ethereum
Oracle-platform
Oracle-platform has two many tasks: managing the information feeds by the
Oracle-DAO and managing the shares of partner DAOs.
2.1
Now, suppose the Oracle-platform has the partner DAOs: DAO-1, DAO-2, ...,
DAO-N, which are also traded on chain and have a market capitalization of
M1 , M2 , ..., MN nominated in Ether. Furthermore, the Oracle-DAO itself has
also shares with a valuation of M0 . The shares of the partner DAOs should be
linked in a way such that:
1. the DAO-Oracle is knowledgeable about the market capitalization of M1 , M2 , ..., MN
2. the DAO-Oracle can create a copy of DAO-I: DAO-I
3. the DAO-Oracle can buy all shares of DAO-I for the current market price
MI .
Using this setup, the following escalation process can be implemented, in case
the Oracle-DAOs server are not working a predefined way.
2.3
Escalation process
Now, let us assume that the Oracle-DAO information feed is broken. Which
scenarios of broken feeds can happen, is described in the next sections as well.
Due to the set up of servers anybody can verify this and report this event to the
Oracle-DAO smart contracts. Then the Oracle-DAO will initiate a betting about
the truth in a similar way as the Schelling coin mechanism: Anyone can either
bet Ether or shares of DAO-0 to DAO-N on the outcome of the questions: Was
this report saying that the feed is broken issued to the Oracle-DAO rightfully?
Let us define the valuation of Ether and shares from the DAOs bet for the fact
that the oracle is working: W and that it is not working: NW. Furthermore, let
us define:
M = MO + M1 + M2 + ... + MN
(1)
Then we have following cases:
Case 1: W < N W and W < 45 M In this case, most of the Ether or shares
have been bet for the fact that the oracle is not working properly. Thus the
smart contracts will assume that the oracle is indeed not working properly. The
smart contracts will stop any settlements on recent feed information. Everyone,
who bet on and contributed to NW will be reward by distributing the Ether and
shares bet on W to them.
Case 2: N W < W and N W < 45 M In this case, most of the Ether and
shares have been bet for the fact that the oracle is working properly. Thus the
smart contracts will assume that the oracle is indeed working properly. Oracle services will continue. Everyone, who bet on and contributed to W will be
rewarded by distributing the Ether and shares bet on NW to them.
Case 3: N W > 54 M and W > 45 M In this case, a lot of Ether and shares
has been spent on the both sides of the bets. It might be that the betting process
is attempted to be manipulated by a very big player. In order to counter that a
new escalation stage is needed: risk free betting with DAO split.
Once this last escalation level has been reached, the smart contracts are
doing something drastic. They are using the funds from the first escalation stage
and exchange Ether for the shares from all DAOs: DAO-1, DAO-2,...,DAO-N
and Oracle-DAO at the last price of the shares nominated in Ether before the
escalation process started. Every shareholder of one of the DAOs will receive
the net worth of their shares paid in Ether, but in return the smart contracts
acquiring their shares.
The next step is that all DAOs will get split. Each DAO-k will get a copy
DAO-K and the Oracle-DAO will get a copy Oracle-DAO. DAO-K will be a
fully working DAO, but the Collateral and holdings of Ether of the DAO-K will
only be kept in DAO-K and not in DAO-K.
Now everything is set up for the final risk free betting. Now everyone in the
whole Ethereum ecosystem can again bet whether the oracle was working (W)
or was not working (NW) properly. One simply votes by sending Ether and his
vote. After 3 weeks of voting, we have a certain amount of Ether spend on W:
#W and a certain amount of Ether spend on NW: #N W .
Case 3.1: #W > #N W In this case, the majority bet that the oracle was
working. Now, everyone who spent Ether in the second escalation get its Ether
back. Also, everyone who voted for W will get a proportion of 30 percent of
shares from the DAO-1 to DAO-N proportionally to the amount of Ether he
bet on. The people voted for NW will get as rewards 30 percent of shares of
the DAO-1 to DAO-N. The first stage escalation bet will be resolved using the
outcome of this second escalation bet: people who bet for NW will lose all their
funds inputs, but will be rewarded with 70 percent of shares of the DAO-1 to
DAO-N. And people who bet for W in first escalation will get rewarded with
70 percent of shares of DAO-0, to DAO-N and will receive in total 90 percent of
their fund inputs.
Case 3.2: #N W > #W In this case, the majority bet that the oracle was
not working. Now, everyone who spent Ether in the second escalation gets its
Ether back. Also, everyone who voted for NW will get a proportion of 30 percent
of shares from the DAO-1 to DAO-N proportionally to the amount of Ether he
bet on. The people voted for W will get as rewards 30 percent of shares of the
DAO-1 to DAO-N. The first stage escalation bet will be resolved using the
outcome of this second escalation bet: people who bet for W will lose all their
funds inputs, but will receive 70 percent of shares of the DAO-1 to DAO-N.
Furthermore, people who bet for NW in first escalation will get rewarded with
70 percent of shares of DAO-0, to DAO-N and will receive in total 90 percent of
their fund inputs.
Additional security measurement for second escalation stage Customers
of all Dapps and DAOs should have the chance to settle their financial products/services with the last price/information feed available before the report of
a broken information feed, if the second escalation stage has been reached.
Using this approach, customers of the DAO-1 to DAO-N can comfortably
leave the DAO service without any risk of losing much money. In case the second
escalation betting is not revealing the truth in their opinion, they use this exit
in order to be not depended on a non-reliable information feed. They can use it
also in order to switch from DAO-I to DAO-I - the newly created DAO.
As shown later, the costs of getting into the second escalation stage are very
high and can be increased by adding more DAOs to the DAO-platform. This is
why the platform can be built in such a way that is always very unprofitable to
push the first escalation betting stage to the second stage for a price manipulation
attack (cp. 5).
Incentive model: The amount an attacker must spend for getting into the
second escalation stage is:
4
4
M = (MO + M1 + M2 + ... + MN )
5
5
(2)
Since the second stage betting is risk free, he probably can not over vote the
majority of honest betters, if he does not bribe them. If the honest better is
revealing the truth, he will be awarded a proportion of valuable shares, which
should have a worth of around M. But if the honest better bets for the manipulator, he will get worthless shares of DAOs, which have no proper working
feed. Thus the normal reward for betting against the truth is just 0. Hence a
possible manipulator needs to hand out a bribe of at least 0.3 M + epsilon.
Here, epsilon stands for the additional bribe that users are getting for voting
for the manipulator. This bribe would need to be shared among all people, who
bet against the truth and for the manipulator. Thus the total cost for an attack
should be:
4
(3)
Cost = M + (0.3 M + epsilon)
5
If the attack is successful, the manipulator would get 90 percent of his stake from
the first escalation bet back and he would also get the worthless DAO shares.
Hence, we have
Revenue = 0.9 M + 0
(4)
Thus, he ends with a loss of
Balance = Revenue Costs = 0.1 M (0.3 M + epsilon)
(5)
Taking the unrealistic scenario that an attacker can manipulate the betting
procedure without any bribing, he would still lose 0.1 M ;
3
3.1
This method has been known for quite some time in block-chain research [2]. On
Devcon2 Mircrosoft announced that they will offer this service of an verifiable
and trusted computation environments as special middleware for blockchains.
[1]. We will show quickly the original idea, in order to show the reader what is
happening under the hood. The concept for a deployment on AWS from [2] is
to create a machine image with a set of programs and scripts on a server and
publish all the information needed to enable everyone to verify that right now
exactly this published machine image is running at a dedicated server provider.
Let us call this machine image with the set of programs and scripts for the
price feed oracle. Imagine this oracle machine image is running on major SaaS
providers, as for example Amazon Web Services, Google cloud platform or Mircosoft Azure and is sending information signed with private keys protected by
dedicated Hardware Security Module (HSM) [4] to the block-chain. Smart contracts on the block-chain are then verifying the information, comparing and
averaging them to calculate an official price feed and signaling possible irregularities in the data. This way, a solid information flow from central servers to
smart contracts is built. Of course, this method has weaknesses, as for example,
what happens if oracle server operators collude and decide to sign wrong information with their private keys from the oracle server. But in such a scenario
other methods will save the information feed. First, we describe the details of
this method:
technical setup In order to demonstrate the method described above, we describe how to set up an oracle server.
The oracle server is supposed to run the following software:
a client software that reads price feed requests from the block-chain
a script that performs the requested price feed request via TLS
a client software that creates transactions for the block-chain with price feed
information
The Oracle-platform has three major advantages over other information feed
provider:
Concluding from previous section, this price feed model has only two major
attack vectors: 1st many oracle servers get compromised at the same time and
2nd the escalation betting does not reveal the reality.
The first attack vector is very unlikely to succeed, if the DAO chooses server
admins carefully, oracle servers are hosted at different companies and if these
oracle servers are constantly reviewed for their trustworthiness. Also, there is no
direct incentive to compromise the price feeds, since an attacker can not profit
from it. And even it happens the escalation process will protect all users funds.
The second attack vector is also very unlikely to succeed and even when
the attacker succeeds to push a new subjective truth into the system, he will
do this with a huge loss. Furthermore, user funds are never at risk, due to the
allowance of settlement with the last price feeds that were confirmed before the
attack.
Hence, DAOs using this Oracle-platform, as for example a derivative marketplace DAO, should be as secure as a traditional exchange regulated by governments.
References
1. https://github.com/Azure/azure-blockchain-projects/blob/master/bletchley/bletchleywhitepaper.md
2. https://bitcointalk.org/index.php?topic=301538.0
3. http://www.oraclize.it/
4. https://aws.amazon.com/cloudhsm/
5. https://blog.ethereum.org/2014/03/28/schellingcoin-a-minimal-trust-universaldata-feed/
6. https://blog.ethereum.org/2014/05/06/daos-dacs-das-and-more-an-incompleteterminology-guide/
7. https://tlsnotary.org/