How to Spot a Rollup in the Wild

EDCON 2023 · 22 May 2023 · 11:55

Toghrul Maharramov, a senior researcher at Scroll, defines a rollup through the security guarantees it inherits from its base layer. He examines data availability, censorship resistance, ordering, validity and recovery, then compares these requirements with the limitations of existing implementations.

Speakers

Topics

From EDCON 2023, hosted by EDCON.

Transcript

hello everyone my name is still girl I do research at scroll and today we're going to be talking about Roll-Ups specifically how to spot a roll up so imagine you're Chris from uh the second generation of Pokemon games and it's a playable character there and your task is to pick her all up and as anyone who played a Pokemon game even once they know that it's quite difficult to pick the right starter do you go with the looks or the stats or the properties and Deluxe means that you choose whether it's cool or cued the Pokemon that you choose and stats you go

a bit more analytical and think what will be the one who what will be the starter that will benefit you the most when you go through the game so if you go through the looks a bunch of cool logos a bunch of cool uis everything looks cool but how do you pick the right one this is a chart from L to beat specifically the risk section of l2bead and you can see a lot of yellow and red here and that's not good that means that these protocols oh sorry uh these Protocols are not actually Roll-Ups they are what vitalik calls Proto Roll-Ups so

they are at a stage where they are slowly becoming compliant with what the majority would agree is a definition of roll up but they currently are not compliant with all the requirements so let's define what a roll up as a roll-up is an off chain protocol that inherits the following security properties from the underlying base layer one data availability so and what's data availability so uh data availability is the process of making the data available to anyone willing to download it for some predetermined

amount of time usually a few months or a month and note that you shouldn't confuse data availability problem with the store data storage problem the data storage problem is the process of making the data available for you to download forever second property that is also very important is censorship resistance and censorship resistance it's quite difficult to Define uh and I'm not going to go very technical into the definition of of censorship resistance now because I'm just gonna bore you to death but uh let's just Define uh censorship resistance for the sake of this exercise as a process within uh which within some predefined period of time uh the

protocol guarantees that the user generated transaction will be included so in this case that would be if a user submits a transaction to an L1 the nl2 the L1 guarantees that that transaction will be included within some time let's say 24 hours for example another important property is ordering so what is ordering ordering is the process of guaranteeing that a certain sequence X is finalized once uh once the or once the underlying layer finalizes it so in this case for example if you have a batch of transactions

and you commit them to the L1 and as soon as the L1 finalizes that transaction order you can no longer revert it so that's a universally agreed upon ordering so unless something uh really catastrophic happens on that one you you basically have to accept that that's the canonical ordering another property that is important is validity though note that in here validity means that we need to make an additional assumption so in case of an optimistic roll up you need to assume that there is one honest node that is capable to challenge a state commitment so essentially let's say if somebody

submits a batch with an incorrect State commitment another person who's also running an L2 node is running an L2 node has to spot it and then challenge that state commitment on chain and for zero knowledge roll ups the assumption is a bit different you just need to assume that the zero knowledge proof system that you use is actually functioning correctly so let's say if you're using graph 16 or hello to you just need to assume that the system that you're using does so in this case grow 16 is functioning as as intended and it's not broken and validity is the process of making sure that the execution is compliant

with the state transition function defined by the protocol so in this case we ensure compliance either through fraud proofs or zero knowledge proofs depending on the specific Roll-Up and another property is temporary bridge and mutability so what does temporary bridge immutability mean it's when an initiated Bridge upgrade actually allows users ample time to exit in case there's something that they disagree with so unfortunately for now it's difficult to imagine that general purpose Roll-Ups are gonna be ossified or we could make the contracts immutable for the foreseeable future and so

there's going to be some form of upgradability either through governance or some form of Security Council or something like that and we need to make sure that the user who doesn't agree with the upgrade so for example there's a malicious code being injected like for example what happened with tornado cash the other day uh there's always a way for that user to exit prior to the prior to that change being enacted so vitalik in his article defines the the time required as 28 days I usually say that it's around a month so let's say four weeks is more than enough for the majority of the users to exit if

something is wrong with the upgrade and finally we have permissionless liveness recovery so what that means is in a lot of cases a roll-up will adopt its own consensus mechanism so for example it will run bft or some form of other consensus mechanism that will basically allow it to have faster confirmation times that the underlying layer but the disadvantage of that that in a lot of cases those consensus mechanisms are permission so for example if you use tender mint you can only have a few hundred validators participating in the consensus and what happens if that consensus fails so there's aliveness failure

and if you don't have any way to recover it's essentially stuck and you need to use some form of upgrade ability or something like that to recover which is not a great option and so the roll up should have a fallback path so if you refer to the consensus path as the happy path the rollup should also have a happy path that allows anyone to commit blocks or batches to the underlying layer if no batches were committed by the consensus within a certain amount of time let's say an hour or two or whatever it really depends on a specific implementation so now that we got through all the properties this is the only

roll up on ltp that actually compliance with those with the definitions that I listed below uh before uh unfortunately it's not a general purpose roll up so it's a payment roll up so you can only transfer money from one person to another and also it has eight dollars of tvl on it so not a lot of people use it and while everybody else including us at scroll we're trying to improve the security properties Etc still will take some time before all of us can be compliant with the current definition of a roll-up and so for now we're all stuck with some form of safety precautions or some form of multi-cigs which will make

us I think vitalik uses type 0 and type one uh training wheels so we are essentially Pro Auto roll-ups and a bit of a side quest here we're also gonna bust some myths so you noticed how I never mentioned centralization when defining what a rollup is and you might rightfully ask but what about centralized sequencers but in reality centralized sequencer is a ux problem in a roll-up it's not a safety problem so because the underlying base layer provides us with the guarantees of correctness we don't really rely on the sequencer for that we just need the

sequencer to provide some form of real-time censorship guarantees censorship resistance guarantees because even with censorship resistant a sequencer a centralized sequencer is unable to censor us permanently it can only do it temporarily oh so the centralized sequencer orders some stronger real-time censorship resistance guarantees and that's it and basically the reason why using a consensus makes sense for Roll-Ups is because it's just easy and it's the easiest way you can decentralize there are obviously other ways you can decentralize it for example Justin Drake has this proposal of using

Searchers to create bundles and basically have the same properties at as the L1 but there are also downsides there so it's just picking whatever works best for you and another myth the I've been seeing a lot on Twitter recently is the an L2 with a sovereign consensus mechanism basically is just another one which is also completely not true and nonsensical and the reason why it's not true is because as I previously said the roll up just doesn't

provide separate safety guarantees correctness guarantees etc etc so when you think about an L1 an L1 consensus provides certain guarantees so it offers ordering guarantees as well as da and validity guarantees for light clients whereas roll-up consensus doesn't do that it's just used to provide better real-time censorship guarantees and that's it and therefore the reason why we use consent some of us will use consensus mechanisms and roll ups is not the same reason why you would use a consensus mechanism for an L1 the reasons are completely different yeah thanks for listening it's been a

bit of a short talk and if you have any questions feel free to ask [Applause]