Beamer - an optimistic bridge

ETHCC 5 · July 2022 · 15:04

Frederik Lührs explains Beamer, an optimistic bridge focused on rollup-to-rollup transfers. The presentation connects its technical choices with a user-centered design process.

Speakers

Topics

From ETHCC 5, hosted by Ethereum France.

Transcript

foreign I'm the protocol architect of beamer and today I'd like to talk to you about effortless optimistic bridging between Roll-Ups only and what nice properties we can gain out of that so Bridges bridges everywhere with the last bull market and ethereum being congested quite often we saw the car as a consequence that many users are actually leaving ethereum to Old l1's other side chains and we also have Roll-Ups emerging um so actually fragmenting all that into

different networks we see the need of bridging assets between those networks and whenever you have such a fast-growing segments in crypto you also see the hex are not far away and that's what we have seen probably the most famous the Ronin Bridge hack as the best example just a couple of months ago and that really often happens because there is making comp there are trade-offs being made in the security assumptions of the protocols so when we started researching in this field we figured out that lots of bridges are actually trying to do it all they want

to connect between all the l1s the side chains roll ups all what they have and as I mentioned as a consequence they need to make compromises compromises on user experience or on security or whatnot so we as the bema team we believe in a roll-up Centric future for ethereum and we believe that Roll-Ups will succeed in the long term so when talking about making a bridge it was a no-brainer for us actually to build a bridge and roll ups and if we go that route and actually build a bridge only for Roll-Ups we can take advantage of the nice properties Roll-Ups have namely data availability

on the common base layer so this means actually having all data from all rollups on a common base layer like ethereum L1 in theory all of the state of all the rollups can be evaluated and verified so whenever something goes wrong on any roll up we could as a cons like as a last resort go to L1 and actually evaluate what happened so but to be honest when speaking about bridging between roll-ups that's actually not what we want we don't want to use L1 actually so how can we that that's basically the

purpose of the bridge so um it would definitely not be very good user experience if the user had to go to L1 and do slow and perform slow transactions so the question was here and the challenge how can we build a protocol that maintains this security level and does not add or does not add a lot of new trust assumptions and at the same time maximize on user experience a very smooth user experience and our solution to this is bema bridge and the underlying protocol and which is what we call an optimistic bridge and how that works and how we can

achieve a maximum user experience while maintaining a very high level of security I'd like to explain to you in a minute so but just to re-emphasize on when we are talking about bridging Bima Bridge enables the user to transfer esc-20 assets between all between any evm compatible roll up which is built on ethereum layer 1. so basically what is bema Bridge Beamer Bridge is a market making protocol between a user who wants to transfer funds and liquidity providers who have those funds on other rollups

we use canonical tokens so we don't have a lock and mint mechanism we use the native tokens created by the roller bridges that guarantees even higher level of security and um so if a user wants to transfer the tokens it's basically written on the left he has his tokens on roll up one and census tokens and performs one transaction and sends the tokens additionally with some fees and the request that information on one of our contracts as soon as a liquidity provider we call them agents sees that

he will immediately send the tokens on the target roll up to the user so that actually means the service is provided at that point in time so the user can actually has received the tokens and can move on with his life and use some D5 tools or whatnot so but the question is of course a an agent would only upfront the assets if he really knows and can be really sure that the he will get back his tokens which are locked in the contract um so and that's where our optimistic Bridge comes into place

the agent will go to that contract and makes uh makes a claim that he's the one who fulfilled the service on the target Roll-Up so no please note that everybody outside of the Roll-Ups like any participant in the network can read the roll up and and it really knows if he actually provide it and if this claim is valid or not um only the contract itself doesn't know it yet so um once the agent did his claim he will actually in a period will start where any participant can intervene and

make a statement that he believes this claim is not valid so enter into a dispute between two participants but if that doesn't happened and that's a happy case this period will simply expire the agent will withdraw the tokens and the trade is actually settled that easy but of course the interesting part is what happens if we have a dispute how can we correctly resolve this dispute because definitely one of the participants is lying so looking into that phase it's called The Challenge phase one should know that the agent when making a claim needs to stake a

small deposit which he is willing to lose if this claim is an invalid claim so that doesn't that amount doesn't need to be very high but it must be enough that any participant in the system is incentivized to actually step in and join this challenge so let's assume that happens and there was someone believes that is a false claim and he will also stake a small deposit and now we are entering into a challenge period so in this period we introduce a escalation game mechanism that mechanism is also known for example in clarus where both participants

both participants can will outbit each other and increase their stakes in the game so um that is very important for later but just see it like as a game of poker where both of the participants can increase their stakes and once the claim is resolved the winner will get all the stakes um so how is the claim actually resolved so there are two possible ways that a claim will be resolved or a challenge in that case um for one any participant could stop engaging in the protocol and the challenge period time window expires

at that point in time the highest bidder will be seen as the actually the person who said the truth and will win this claim so when will win all the stakes if it's the claimer he's also possible he's also able to withdraw the tokens if it's a challenger then the claim is not possible so basically the contract simply believes that the highest bid is saying the truth but of course that wouldn't be very secure if that would be the only option because um uh the more economic power one has um the more likely it is that he will win a claim but we actually want the person who's making a valid statement

will will win all the time so what is the other way and the other way is actually something we need to remember from the beginning of the talk we're doing roll-up only bridging and the nice property of rollapses all the data are available on ethereum layer 1. so whenever the honest participant feels like it or actually any participant he could simply go to L1 execute the transaction verifying the state what really happens happened on the target roll up and what's then technically actually happening is the layer 1 contract will transmit this information to the

contract to the dispute and it will resolve with the real outcome because that's the actual information and the actual action what happened on the target roll up so um I just said in before that this bidding phase is very important and the bidding phase is important because going to layer one can be quite costly so and an honest participant should never pay for it so this bidding phase is actually there to collect funds from the malicious party to eventually pay for this transaction so from to have a little bit of a different view on it

we see a flow diagram of an honest user and I will show you now that the claim will always be resolved correctly if the honest user just follows the protocol um it's the starting point here at this part um the user so we're assuming that the honest user is winning so he has the highest bid right now then he will just check if it's already terminated then it is resolved correctly because the honest participant won the challenge um if not he will simply check did I get challenged so is the other party leading now and if yes

um is there enough stake already deposited by the malicious party so it will cover my cost to go to L1 if not then I will simply increase my stake enforcing the other one to um bid as well as much money so it simply Cycles back but if there's enough stake collected then we will do or the honest participant will do what we call an L1 resolution actually verifying the state of the target roll up and transmitting this information to the contract and we will also and obviously with a correctly resolved claim so as you can see if one of the

participants is honest so we only need ever one honest participant um we will and this one follows the protocol we will always end in correctly resolved claims um that protocol is actually in place to and so we see that the malicious party will always lose so we put that protocol in place but we actually expect that it is never or rarely going to be used um and it's just being used as a Potential Threat to any malicious actor if them if there is still a militia sector wants to enter into this challenge um he will for sure end up losing money yeah that's already it I showed you how

we can achieve um very good user experience while maintaining ethereum layer 1 security um please before we go into questions visit us at our booth it's in the basement level -1 next to the catering you can try out bhima there and get some nice whack or just try it out yourself at testnet.bemabridge.1 dot com and yeah so if you're interested you can also join our Discord thank you very much um do you have questions [Applause] you have time for one question if

anybody would like to ask anything all right yeah question yeah that's a very good question so um as we have shown in the slide before the user is actually done once he received this transfers but the dispute resolution will only ever happen between agents and they do it for profit and they do it because they are service providers okay no worries um you can see me now

later or at the booth I'm happy to go into detail thank you very much thank you thank you