19 matches found
LPDA sale getPrice() will be broken after time because of overflow calculation
Lines of code Vulnerability details Impact LPDA sale is stand for βLast Price Dutch Auctionβ, which means price will drop every second from startPrice. After all NFTs are saled, it will recorded the finalPrice at the time the sale finished with the formula startPrice - dropPerSecond timeElapsed...
Malicious feeReceiver or saleReceiver can steal the user's refund ETH by calling the buy function multiple times in LPDA
Lines of code Vulnerability details Impact In the LPDA contract, the fee is transfered to feeReceiver and the totalSale to saleReceiver when newId == temp.finalId, meaning that the amount of tokens that were minted has been reached. However, the call to the internal end function only emits an eve...
LAST PRICE DUTCH AUCTION SALE (LPDA) CAN BE EXPLOITED
Lines of code Vulnerability details Impact The function logic of buy in LPDA.sol can be exploited by shrewd buyers to achieve the lowest finalPrice possible. Proof of Concept LPDA.solL58-L89 function buyuint256 amount external payable uint48 amount = uint48amount; Sale memory temp = sale;...
Loss of ETH for NFT buyers in LPDA contract
Lines of code Vulnerability details Impact The buy function of LPDA sale contract can be invoked with 0 as the input value and 0 ETH as the sent valuemsg.value = 0. The buy function automatically ends the sale when newId == sale.finalId and distributes ETH to feeReceiver and saleReceiver. Since t...
Not possible to finish LPDA after endTime
Lines of code Vulnerability details Vulnerability details The only way to finish the sale is when newId == temp.finalId, making not possible to finish LPDA even if the endTime is already over POC There isn't any function to finalize the LPDA sale even if already finished the sale, the only way to...
Implementing Security Restrictions and Owner Access Controls on LPDA Smart Contract.
Lines of code Vulnerability details Vulnerability details Impact The new changes to the contract add an additional layer of security and restrict access to certain privileged functions. The buy function now requires that only the owner can purchase tokens, which prevents malicious actors from...
LPDA refund logic is broken, meaning buyers always get lowest price sale
Lines of code Vulnerability details Impact The protocol intends the LPDA to refunds buyers with the difference between the price they paid and the last sale price Once the sale has ended, the users must call refund to get their Ether refunds based on their purchase price and lowest sale price 99:...
underflow in the getPrice() function can block the buy and refund in the LPDA sale
Lines of code Vulnerability details Impact In the LPDA sale the price decrease in values after each second, and when creating the sale the value of the lowest price possible is not checked, so the price could go below zero at a given timestamp which will lead to an underflow in the getPrice...
Buys and refunds can get stuck forever if the parameters are not set sensibly in the LPDA
Lines of code Vulnerability details Impact In the LPDA contract, there is a function called getPrice which returns the price of one token by taking into account the drop in price per second of the Dutch auction. It basically calculates how much time was elapsed since the start of the sale, to...
Possible negative price on LPDA causes sale and refund mechanism to not working
Lines of code Vulnerability details Impact Possible negative price on LPDA causes sale and refund mechanism to not working Proof of Concept function getPrice public view returns uint256 Sale memory temp = sale; uint256 start, uint256 end = temp.startTime, temp.endTime; if block.timestamp...
The LPDA will keep minting NFTs after the endTime
Lines of code Vulnerability details Impact The users would keep minting from LPDA even if the end time was reached Proof of Concept Please copy the following test on LPDA.t.sol import IEscher721 from "../src/interfaces/IEscher721.sol"; function testRevertsWhenEndedBuy public testBuy; // the testB...
wrong configuration can lock eth in LPDA contract forever
Lines of code Vulnerability details When creating an LPDA auction there are some sanity checks of the values used for the auction. But there is no check that the auction will not cause the price calculation to underflow after a while. This calculation of the price can underflow in getPrice in...
LPDA can be initialized with parameters that will revert getPrice()
Lines of code Vulnerability details Impact LPDA Sales can start reverting the buy and refund functions at some point of time if initialized with incorrect parameters revert happens at getPrice function. Users might not be able to withdraw their excess balance using refund function if getPrice...
Funds reserved for refunding users can be steal in LPDA sale
Lines of code Vulnerability details Impact LPDA sale works like a Dutch Auction, where early buyers will get refund after the sale ended. In addition, in buy function, when last NFT is saled, it is automatically ending the LPDA sale and send payments to sale receiver, fee to fee receiver. And the...
Ether can be lost in LPDA contract if sale.dropPerSecond is set improperly
Lines of code Vulnerability details Impact Function createLPDASale requires only sale.dropPerSecond 0 but if sale.dropPerSecond sale.startPrice / sale.endTime - sale.startTime function getPrice will revert except the case when all editions are sold before reaching negative price. Therefore, the b...
The LPDA will fail, because the Arithmetic underflow
Lines of code Vulnerability details Impact The LPDA will fail to buy mint new NFTs even if block.timestamp = temp.startTime , block.timestamp = temp.endTime and newId sale.dropPerSecond sale.endTime - sale.startTime, "INVALID DROP PER SECOND"; --- The text was updated successfully, but th...
The Ether for an LPDA mint sale can be locked in the LPDA contract indefinitely
Lines of code Vulnerability details Impact After a mint sale using LPDA, all the Ether can be locked in the LPDA contract indefinitely. Proof of Concept In the src/minters/ contracts, the .transfer function is used for sending Ether. It is used for sending fees to the feeReceiver, and in the...
LPDA sales can potentially have buying function reverting indefinately due to negative price
Lines of code Vulnerability details Impact While i'm assuming there are checks for this on UI or off-chain, this wasn't mentioned in the docs or the comments, so its worth flagging and possibly implementating the mitigation step as a precaution since it is also cheap on gas. The price can...
LPDA price is not calculated correctly such that it won't end at the final price as expected
Lines of code Vulnerability details Impact LPDA price is not calculated correctly such that it won't end at the final price as expected Proof of Concept function getPrice public view returns uint256 Sale memory temp = sale; uint256 start, uint256 end = temp.startTime, temp.endTime; if...