FC4-04 | Possible Inconsistencies Between Sifchain States And Smart Contract States #3153
Labels
Major
Reported as a major Vulnerability
Peggy Team
Peggy team task
Peggy 2.0
An issue blocking the Peggy 2.0 release
Let's huddle to discuss the best way to resolve this issue. @banshee @smartyalgo @Brando753
Description
Events emitted by the smart contracts will be synced to the Sifchain, and events on the Sifchain will also be synced to the smart contracts after collecting enough validator signatures, so smart contract states, such as the power of validators, consensus rate, and blacklist, should be consistent with Sifchain chain states after syncing. However, due to the latency caused by the syncing process, the smart contract states and the Sifchain states are not always consistent.
For example, the relayer checks if a event has collected enough validator signatures on the Sifchain:
After the event is submitted to the Ethereum chain, the signatures will be checked again, include the validity of the signer's identity, the legitimacy of the signature and the consensus rate:
However, it is possible that the state of a validator is changed, for example, a new validator has been added to the
validatorWhiteList
on the Sifchain, but the change has not been synced to the Ethereum chain. Therefore, the signature check might be passed on the Sifchain but fail the checkup on theCosmosBridge
contract.Recommendation
Recommend checking if the corner cases caused by the aforementioned inconsistencies are acceptable, if it is not, modifying the syncing mechanism to ensure consistency.
The text was updated successfully, but these errors were encountered: