The function verifyPeriodByStateRoot verifies an Ethereum state proof proof_rlp against a known state_root obtained from a block oracle. It extracts a period value from storage via _extractPeriodFromProof and updates an oracle contract with the extracted without any implemented valiadation to proof_rlp
Without any validation checks the function is vulnerable to:
Revert on Malformed RLP Proofs – If _proof_rlp is invalid, toRlpItem().toList() would revert, wasting gas and causing unexpected failures.
Oracle Update with Invalid Data – Without checking period > 0, the contract could push incorrect values to the oracle, affecting downstream logic.
Invalid state_root Usage – If state_root == bytes32(0), the proof extraction would fail unpredictably, leading to unnecessary gas consumption.
Gas-Wasting Attacks – Attackers could spam invalid proofs, forcing expensive revert operations and potentially disrupting oracle updates and also causing DoS attack.
Implement following checks:
- All proof generated within `_proof_rlp` is generated via the off-chain prover, so there is no concrete proof that this proofs are non-unique. - All state roots and proofs must be verified by the OOS `StateProofVerifier` inherited as `Verifier`, so there is no proof that manipulating proofs can successfully pass a price update
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.