NethermindEth / Taiko-Preconf-AVS

11 stars 6 forks source link

allow any address to call `addValidators` #167

Closed dantaik closed 1 day ago

dantaik commented 1 day ago

The addValidators function is only callable by the preconfer for which the new validators will be added. But since the validators has already authorized this operation with a BLS signature, maybe we can allow any address to transact addValidators? Or do you think adding validators should have "approvals" from both validators and the preconfer - the fact that only the preconfer can transact this function servers as another "approval".

AnshuJalan commented 1 day ago

So, earlier it was designed in the way that you suggested, where anyone can add the validator, but we realised that we still need to only allow just the validators that the preconfer "knows" to be a part of the validator set. If a random validator has added itself to the preconfer and the preconfer is now in the lookahead, the preconfer must be wary of preconfing since there is no guarantee of inclusion in the block. So, we either manage this "approval" flow on the preconfer's node or in the contract by simply allowing only the preconfers to add validators. We settled on the latter.