Lucene search
+L

4 matches found

Code423n4
Code423n4
•added 2022/11/21 12:00 a.m.•16 views

Upgraded Q -> M from #418 [1669043788344]

Judge has assessed an item in Issue 418 as M risk. The relevant finding follows: 1. LBRouter's swapAVAXForExactTokens not working as intended LBRouter's swapAVAXForExactTokens will only work when sending exact msg.value = amountIn0. The functionality which returns excess funds to the user in the...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/10/24 12:00 a.m.•26 views

LBRouter's swapAVAXForExactTokens is unavailable when any extra AVAX funds supplied

swapAVAXForExactTokens logic includes transferring out the excess amount of the native funds supplied by a caller. However, amountsIn0 - msg.value amount that swapAVAXForExactTokens calculates for transfer out is negative. The reason is the inverted amount calculation, i.e. according to the logic...

6.5AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/10/23 12:00 a.m.•15 views

Wrong calculation in LBRouter._getAmountsIn.

Lines of code Vulnerability details Impact It calculates the amountsIn wrongly here and the function returns the wrong result. Proof of Concept Currently, getAmountsIn calculates the amountsIn like below. amountsIni - 1 = reserveIn amountOut 1000 / reserveOut - amountOut 997 + 1; As we can see...

6.9AI score
SaveExploits0
Code423n4
Code423n4
•added 2022/10/23 12:00 a.m.•22 views

Wrong calculation in function LBRouter._getAmountsIn make user lose a lot of tokens when swap through JoePair (most of them will gifted to JoePair freely)

Lines of code Vulnerability details Vulnerable detail Function LBRouter.getAmountsIn is a helper function to return the amounts in with given amountOut. This function will check the pair of token and tokenNext is JoePair or LBPair using binStep. If binStep == 0, it will be a JoePair otherwise it...

7.1AI score
SaveExploits0
Rows per page
Query Builder