arbitraryCall
enables streamCreator
to remove incentive tokens before endStream
#174
Labels
3 (High Risk)
Assets can be stolen/lost/compromised directly
bug
Something isn't working
duplicate
This issue or pull request already exists
Handle
bitbopper
Vulnerability details
Impact
streamCreator
can remove incentive tokens before endStream by calling approve on the token beforehand.streamCreator
has following methods of attack:createIncentive
transaction.flashbots
to get executed before thecreateIncentive
transaction.Results in premature loss of funds of the
Stream
contract.Proof of Concept
Improve
LockeTest.sol
with:Add following to
StreamTest
ofLocke.t.sol
:Output
Tools Used
dapptools
Recommended Mitigation Steps
Ensure incoming amount of incentive token is not greater than the existing allowance for that token from the incentive sender at
createIncentive
.The text was updated successfully, but these errors were encountered: