kkrt-labs / kakarot

Kakarot is a zkEVM written in Cairo, leveraging the STARK proof system.
https://kakarot.org
MIT License
907 stars 252 forks source link

design: anti-L1-spoofing messaging system #1229

Open enitrat opened 1 week ago

enitrat commented 1 week ago

Feature Request

The current Messaging System takes the l1_sender address as the caller of the L2 contract invoked.

This can be an issue if, for example, a L2 contract expects to be invoked in specific conditions by another L2 contract, but ends up being called in other conditions by an L1 contract that would match these conditions.

We need to design a system that prevents this from happening:

ClementWalter commented 1 week ago

this requires address collision first right? to be able to have on L1 a contract that has exactly the same address as another on L2