-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: checks address proposer #49
Conversation
@@ -70,6 +70,7 @@ contract BondedDisputeModule is Module, IBondedDisputeModule { | |||
_amount: _params.bondSize | |||
}); | |||
} else if (_status == IOracle.DisputeStatus.Won) { | |||
if (_dispute.proposer != _response.proposer) revert BondedDisputeModule_OnlyResponseProposer(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would call it BondedDisputeModule_SelfDispute()
.
Also add tests for this case
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't see why call it self because this happens when you try to change the address it receives but oka.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indeed, what matters is that the proposer
in the IOracle.Response
struct is expected to be equal to the same in the IOracle.Dispute
struct, despite being arbitrarily inputted by the caller. The fact that someone might dispute himself is not the focus of the issue and apparently is not affected by the reversion above.
… fix/disputer-address
…phet-modules into fix/disputer-address
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't this issue be validated in Oracle.disputeResponse()
?
I agree @0xJabberwock. I prefer if we do it in the oracle! |
🤖 Linear
Closes GRT-12