XDEFIDistribution: _unlock function should only be called with tokenId_ parameter #98
Labels
bug
Something isn't working
G (Gas Optimization)
sponsor acknowledged
Technically the issue is correct, but we're not going to resolve it for XYZ reasons
Handle
PierrickGT
Vulnerability details
Impact
We pass
account_
to the_unlock
function but this one is always called withmsg.sender
as first parameter. We can simplify the code by removing theaccount_
parameter and callingmsg.sender
inside the function instead.Proof of Concept
Remove the
account_
parameter from_unlock
and_unlockBatch
to only usemsg.sender
inside the_unlock
function.Recommended Mitigation Steps
The following changes are recommended.
For the
_unlock
function:On line 112:
On line 133:
On line 326:
For the
_unlockBatch
function:On line 167:
On line 188:
The text was updated successfully, but these errors were encountered: