optimistic-specs
optimistic-specs copied to clipboard
Milestone epic: Deposit fees 💸
Adds the Deposit Fee design currently being discussed in Discussion 112, and issue 78.
The deposit-rollup milestone (v0.1.0) does not charge for deposits or price L2 gas consumption at all: update this with deposit fees.
- [ ] Spec deposit fees
- Update deposit contract:
- [ ] to lock/release deposit funds
- [ ] to update EIP-1559-like fee var
- [ ] Update
core/types.DepositTx
in reference-optimistic-geth - [ ] Update input-derivation in ref impl to parse new deposit receipts into new deposit tx types
Bonus, after the deposit type is well specified and tested: create an EIP for it, see https://github.com/ethereum-optimism/optimistic-specs/issues/75
Could we rename this from "deposit rollup with deposit fees" to simply "deposit fees". AFAICT, there is nothing about this that can't also apply to the sequencer rollup.
Question: Can you shed some details on this (issue 78): "Despite L1's high gas price, it is possible to submit a small deposit that will cause a massive amount of L2 gas to be consumed" Thank you!!
@Graciouseats sure, you can imagine a cross chain transaction with a very high gasLimit
, with zero data
which calls to this contract:
contract Dos {
fallback() {
uint i;
while(gasleft() > 500) { i++ }
}
}
Thanks! Code is not my specialty :} But it seems simple. So what would prevent someone from doing this easily?
@Graciouseats We just have to charge the users for gas somehow. The issue you're highlighting was uncovered when we considered not charging for gas at all in deposits (to make them as cheap as possible).
I see. Thank you for strengthening my understanding, and for providing some history.
@Graciouseats you can find much more context here if you're more of a prose kind of person.
Let's not clutter up this thread more, but we'd be happy to answer further questions in a new discussion, or our discord. :)