fix(ctb): Address DoS vulnerability in OptimismPortal's proveWithdrawalTransaction#4025
fix(ctb): Address DoS vulnerability in OptimismPortal's proveWithdrawalTransaction#4025
OptimismPortal's proveWithdrawalTransaction#4025Conversation
🦋 Changeset detectedLatest commit: 9d06292 The changes in this PR will be included in the next version bump. This PR includes changesets to release 5 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
Hey @clabby! This PR has merge conflicts. Please fix them before continuing review. |
OptimismPortalOptimismPortal's proveWithdrawalTransaction
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## develop #4025 +/- ##
========================================
Coverage 43.59% 43.60%
========================================
Files 328 328
Lines 17156 17158 +2
Branches 781 782 +1
========================================
+ Hits 7480 7482 +2
- Misses 9171 9172 +1
+ Partials 505 504 -1
Flags with carried forward coverage won't be shown. Click here to find out more.
|
maurelian
left a comment
There was a problem hiding this comment.
Left some minor suggestions but generally LGTM
|
Hey @clabby! This PR has merge conflicts. Please fix them before continuing review. |
|
@smartcontracts @maurelian The |
Overview
Fixes a high severity vulnerability in
OptimismPortalthat was introduced in #3836.Prior to this fix, a malicious party could censor a withdrawal by repeatedly proving it, causing the 7 day timer to reset each time. The solution is to not allow any
withdrawalHashto be proven more than once unless the withdrawal is re-proven with a different outputRoot / outputRootProof.Tests
Added:
test_proveWithdrawalTransaction_replayProve_revertstest_proveWithdrawalTransaction_replayProveChangedOutputRoot_successAdditional context
See November 2022 TOB Audit Week 1 report.