Orbiting Rosewood Swallow - Malicious users can createOrder
with 0 amount
and make DOS
for all
#731
Labels
Sponsor Confirmed
The sponsor acknowledged this issue is valid
Will Fix
The sponsor confirmed this issue will be fixed
Orbiting Rosewood Swallow
High
Malicious users can
createOrder
with0 amount
and makeDOS
for allSummary
Malicious users can
createOrder
with 0 amount and can causeDOS / block users
tofillOrder
,cancleOrder
Impact
Malicious users will create huge numbers of orders with
0 amountIn
.Now if anyone wants to
fillOrder
orcancleOrder
they can not do it because:ArrayMutation::removeFromArray
is called onfillOrder
,cancleOrder
functions.fillOrder
orcancleOrder
they simplyrun out of gas
while iterating a huge array ofpendingOrderIds
.fillOrder
,cancleOrder
PoC
OracleLess::createOrder
Mitigation
We can add checks for the
createOrder
function something like thisOr can add code like the other Contracts
MASTER.checkMinOrderSize(tokenIn, amountIn);
The text was updated successfully, but these errors were encountered: