This repository has been archived by the owner on Jul 21, 2024. It is now read-only.
T1MOH - All funds can be stolen from JOJODealer #7
Labels
Has Duplicates
A valid issue with 1+ other issues describing the same vulnerability
High
A valid High severity issue
Reward
A payout will be made for this issue
Sponsor Confirmed
The sponsor acknowledged this issue is valid
Will Fix
The sponsor confirmed this issue will be fixed
T1MOH
high
All funds can be stolen from JOJODealer
Summary
Funding._withdraw()
makes arbitrary call with user specified params. User can for example make ERC20 to himself and steal funds.Vulnerability Detail
User can specify parameters
param
andto
when withdraws:In the end of
_withdraw()
function addressto
is called with thatbytes param
:As an attack vector attacker can execute withdrawal of 1 wei to USDC contract and pass calldata to transfer arbitrary USDC amount to himself via USDC contract.
Impact
All funds can be stolen from JOJODealer
Code Snippet
https://github.com/sherlock-audit/2023-12-jojo-exchange-update/blob/ed4a8483da11bcc04ced10de899038bcead087b3/smart-contract-EVM/src/libraries/Funding.sol#L173-L184
Tool used
Manual Review
Recommendation
Don't make arbitrary call with user specified params
The text was updated successfully, but these errors were encountered: