Core Contracts

Regnum Aurum Acquisition Corp
HardhatReal World AssetsNFT
77,280 USDC
Submission Details
Severity: medium
Invalid

Integer Overflow in Auction.sol

Author Revealed upon completion

Vulnerability Details

The placeBid() function in Auction.sol does not account for potential integer overflow when adding the bid amount to the current highest bid.

Impact

An attacker could exploit this to cause unexpected behavior or bypass bid checks.

Review

Manual review

Recommendations

Use SafeMath Library

Employ OpenZeppelin's SafeMath library to handle arithmetic operations safely.

import "@openzeppelin/contracts/utils/math/SafeMath.sol";
contract Auction {
using SafeMath for uint256;
function placeBid(uint256 bidAmount) external {
uint256 newBid = highestBid.add(bidAmount);
// Bid placement logic
}
}
Updates

Lead Judging Commences

inallhonesty Lead Judge 8 days ago
Submission Judgement Published
Invalidated
Reason: Lack of quality

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.