-
Notifications
You must be signed in to change notification settings - Fork 17
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bounty Claim #29
Comments
Could you tell us more about how BarterDEX and ETOMIC work? |
https://github.com/SuperNETorg/komodo/wiki/barterDEX-Whitepaper-v2 the above describes how barterDEX works, it is a bitcoin protocol based atomic swap DEX, with automated ordermatching via orderbooks |
continuing... It has taken a lot of work to get barterDEX working and debugged to the level it has and I wanted a solution for swapping ETH/ERC20 that had minimal changes to the source code. So I came up with ETOMIC, which is a special purpose coin whose purpose is to dynamically create a custom colored coin, just for a specific swap. the ETH side is locked in a contract to be released only if the corresponding ETOMIC utxo is properly spent via atomic swap protocol. Basically possession of the ETOMIC utxo proves you performed the atomic swap and we have ETH side contracts that implement the various hashlocking and time releases. It is a bit strange, but ETOMIC basically creates a virtual set of utxos for ETH to use for the atomic swap, so we can then use the existing barterDEX to swap ETOMIC as if it was the ETH. With pre and post lock and unlock actions to the ETH smartcontract to make it complete the ETH swap |
SWAP 1806692336-4120247766 finished LP_numfinished.1 !
We have another one. |
ETOMIC is still in testing stage, but so far it is working as intended on the ETH testnet. to change to mainnet, we just need to change the server we are talking to and create the ETH side smartcontracts on the mainchain. Since the ETH smartcontract only has to deal with the hash/time locking/unlocking, it can be streamlined as it doesnt have to deal with any ordermatching, blockchain data posting, etc. The only time ETH transactions are needed are when doing a swap, there is no need for oracles to be posting DOGE chain info to the ETH chain |
The ETOMIC is a special purpose coin that we give out for free. So people shouldnt have problems getting a set of size matched utxos.Well actually we give out free BEER and people can swap BEER for ETOMIC. We will be adding a direct ETOMIC faucet and probably just make it issue the required utxos directly for the requested swap. from: http://www.dexstats.info/ Let me know if you have any more questions. |
We have also complete and inverse swap... ETH to DOGE....
|
First ever ETH/DOGE atomic swap repeated also on mainnet!!!
Proof of Ethereum tx: Proof of Dogecoin tx: |
World Leader in Atomic Swaps strikes again. Kudos Team Komodo :) |
GREAT job Komodo ! |
First DOGE/ETH swap: Proof of Ethereum tx: Proof of Dogecoin tx: |
I've been reviewing the work and I'm still beginning to understand so here are some questions: BarterDEX is a decentralized exchange, not a 1:1 bridge, correct? This means that it always requires two parties, a buyer and a seller. You are showing examples of a swap between ETH/DOGE. That is not what the goal of the bounty, which is a swap between DOGE and a ethereum based token (call it DOGE-TOKEN) which keeps a 1:1 parity with Doge at all times. If that's the case, then the BarterDEX seems like it can be used to solve the first problem: how to create a swap between Doge and any ethereum token, but it doesn't solve the other one, which is how do you create a 1:1 corresponding token. A possible solution could be to try to create a stable coin, using a similar method (or the same method) that DAI uses, that it always tries to keep a 1:1 price parity with Doge. It's a creative solution but it might be badly received on the Doge community: since you are creating a new token with value parity to doge, without removing doge from circulation, then you're effectively increasing the supply of total dogecoins. So that's indeed an interesting challenge: how can you use barterDEX to exchange it with a token with price parity with doge AND not alter the total circulating supply of doge? |
you can deploy marketmakers to swap DOGE for DOGEERC20 at a 1:1 price to solve the coin supply issue, you could burn a corresponding amount of DOGE to the amount of DOGEERC20 created |
@alexvandesande I don't have good grasp of this, but may be this will be helpful somewhere: https://github.com/artemii235/etomic-swap |
Well that would be the MakerDao style solution, but it's easier said than done. I believe another project that can be looked into would be Prism, as it should be theoretically possible to create a huge prism backed by only doge - but again, it requires a counterparty (in Prism's case, it's Shapeshift)
But how do you "unburn" it to make sure you can get it back? Without a full roadmap on how we can turn an atomic swap into a full bridge, I don't feel it merits a bounty. The coinfabrik/truebit team had multiple rounds of conversations before we made the first payment, so I encourage you to make more detailed plans in that direction if you want to receive one too. |
actually to make a 1:1 market for DOGE/DOGE20 is a matter to make a single autoprice api call, it isnt difficult at all: https://www.youtube.com/watch?v=tPLvO0AUYmI the idea is that DOGE20 is created by burning DOGE and it is 1:1 equivalent so the marketmakers are always exchanging DOGE 1:1 for DOGE20, there is no need to unburn it, just swap it back. Our method avoids having to write data regularly to the ETH chain, and I think that is a cost prohibitive approach that btcrelay has. Just use a small fraction of that cost to buy DOGE and burn it and fund the marketmakers |
What exactly are the requirements for being a full bridge? |
I'm speaking solely as spectator, not in any official capacity. @jl777 It's my understanding that a full bridge would be able to allow a party to "transport" its Dogecoin to the Ethereum Network. But what's happening with this "transportation"?
Hopefully my description is accurate but might be wise to wait for 2avsa |
It seems our current solution is very close to the above, it just requires burning the DOGE to create the DogETH. I guess a difference is that in our method, the DogETH that is created lives forever, but not sure how meaningful these differences are. |
The DOGE community made it very clear that a one way bridge (burning doge)
is not welcome for them, as they see it as destroying their currency a bit.
You must be able to go from one and back.
…On Fri, Feb 23, 2018 at 6:15 AM, jl777 ***@***.***> wrote:
It seems our current solution is very close to the above, it just requires
burning the DOGE to create the DogETH. I guess a difference is that in our
method, the DogETH that is created lives forever, but not sure how
meaningful these differences are.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#29 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAG5AgDsweQGxmNTjNyGhvWW1v7FcwYiks5tXoGXgaJpZM4SKva1>
.
--
Alex Van de Sande
Lead Designer
Ethereum Mist Team
|
it might be possible for us to add a way to "atomic swap" against the smart contract to issue the DogETH without any time limit on the redeem. If we added that, would it qualify? Actually it could be that just doing that would be enough |
I don't understand what you meant. How that solves the dogeth->doge issue? |
The only issue with current solution is that to preserve DOGE supply, it required a burn. |
The problem is NOT keeping the doge supply the same (although that is a nice to have), but mainly the burn itself. Can you describe better how this "long term lock" would work? Just a general question: the goal of the bounty is to fund new work to be done on the bridge. My goal with this conversation is to set a framework in which, if you propose a plan of new tech to be developed (using or not tools you already accomplished) I want to assure you that after few months of work it will be rewarded. It's not our goal to give a reward by retroactively fitting existing stuff into something that might be technically in scope. |
Not sure this is what you are saying but an interesting solution to this would be to issue new temporary doge tokens that burn after a given period of time, and after this period the doge itself gets released back. Not sure how this would work as it breaks the fungibility of the doge tokens, but it can be an interesting model. |
There is no need for that. The no-time limit locking of DOGE for DogETH fully solves the requirement as I see it. What part is not fulfulled? DOGE supply is unchanged |
I still don't understand the "locking without time limit" bit. What do you mean by that? |
A special form of an atomic swap where you basically swap the DOGE for DogETH with yourself and it wont have any timelimit. which means you can redeem the DOGE for DogETH at anytime The smartcontract would issue DogETH in exchange for the lock and require DogETH back to unlock the DOGE. not sure how exactly to achieve this, but just saying if we achieved that, would we fulfill the requirements |
Yes. If you are able to do an atomic swap between both then it would be worth a bounty. As a comparison, the Truebit team worked for many months and presented us a working demo which they were able to execute the one way exchange. If you intend to pursue this bounty, then the next step would probably to document it step by step and make live demo you can demonstrate on a video call. |
OK, we still need to explore the feasibility of the no time limit DOGE lock, but that is the only missing step. Once we have a plan for the no time limit lock, I will post again the plan. We are doing the atomic swaps via the barterDEX framework, so getting videos, etc. wont be any problems |
Hello @alexvandesande!
Suggestion B:
Could you review it please and let me know if it make sense? |
That right there seems to throw the whole plan underwater. If we are assuming nice altruistic users, we don't need smart contracts at all, right? Just send your doge to me and I promise it will be ok. Your second proposal is also similar: it's a political peg, not very different than an exchange. I'd note that the current front runner also uses a centralized solution in their way to unlock accounts, but it has been accepted because they are using it temporarily and have produced a compelling argument, using correct incentives, that makes sure if the node doesn't behave well, then it will be punished. Can you see a way in which the whole trust in multisig is unnecessary long term? |
Hi!
We at the Komodo Platform just did a ETH/DOGE atomic swap. We exchanged it in BarterDEX using ETOMIC.
This is the proof:
SWAP completed! 1322053329-1186185224 {"expiration":1519068637,"tradeid":335663668,"requestid":1322053329,"quoteid":1186185224,"iambob":0,"Bgui":"","Agui":"nogui","gui":"nogui","bob":"ETH","bobtomic":"0x0000000000000000000000000000000000000000","etomicsrc":"0x012f7e74120d3d002e8f215ccc6f6f65618f00cb","srcamount":0.04928730,"bobtxfee":0.00001000,"alice":"DOGE","etomicdest":"0x078a1db84a2995c22cb72a390c3d279448dbfbf2","destamount":10,"alicetxfee":1,"aliceid":"2572377750843424768","sentflags":["alicespend", "bobpayment", "alicepayment", "bobdeposit", "myfee"],"values":[0.04929730, 0, 0.04930730, 12, 0.05546821, 0, 0.01287001, 0, 0, 0, 0],"result":"success","status":"finished","finishtime":1519053161,"bobdeposit":"417b4a91650b74e06b84a50cd4f90c757502f9615ae732702a50682f8925d6fd","alicepayment":"df1547ec128a5d78604bd6c6610c6a6e6b096d8f8ced1acb7bb6ed1611f5322f","bobpayment":"6c3a2269a8f3b111142c1291ffc9548bde61fc2d34ec465486e8a4e937c12217","paymentspent":"f2cf1b572d0084684cf1915de608f664604a92eaf3961d04676e7598d6d12d59","Apaymentspent":"0000000000000000000000000000000000000000000000000000000000000000","depositspent":"0000000000000000000000000000000000000000000000000000000000000000","method":"tradestatus","finishtime":1519053161}
bob makes Eth deposit
ropsten.etherscan.io/tx/0xea333077d5753d29909136f950b2ba224312a0a6ed7dd8558350faaacd877c74
alice payment
dogechain.info/tx/df1547ec128a5d78604bd6c6610c6a6e6b096d8f8ced1acb7bb6ed1611f5322f
bob makes Eth payment
ropsten.etherscan.io/tx/0xdf181653159e77194f8dbd91aa397250062e1f1d38d839b300c29d5678711185
alice claims payment
ropsten.etherscan.io/tx/0x874449fb261e1bda008af33bf8264c464a7363140d34d735b2b02e2d0c891db7
bob claims deposit
ropsten.etherscan.io/tx/0xcda27396a376909ef73e86d241f284de0c6bc04a4c9a6bd19834612408d6800c
The text was updated successfully, but these errors were encountered: