Tadle

Tadle
DeFi
30,000 USDC
View results
Submission Details
Severity: low
Valid

Wrong parameter in event AbortBidTaker()

Summary

Wrong parameter in event AbortBidTaker() could cause problems with offchain applications/Dapps, and mislead the end user.

Vulnerability Details

In IPerMarkets.sol the event is defined as follow :

/// @dev Event when taker aborted
event AbortBidTaker(address indexed stock, address indexed authority);

But in PreMarkets.sol :
https://github.com/Cyfrin/2024-08-tadle/blob/main/src/core/PreMarkets.sol#L696

function abortBidTaker(address _stock, address _offer) external {
...
emit AbortBidTaker(_offer, _msgSender());
...
}

It should be _stock and not _offer, according to IPerMarkets.sol:

emit AbortBidTaker(_stock, _msgSender());

Impact

Off chain applications and Dapps relie on informations given by events, this could lead to several problems in applications, misleading the end user.

Tools Used

Github, VisualCode.

Recommendations

Replace _offer by _stock.

Updates

Lead Judging Commences

0xnevi Lead Judge 11 months ago
Submission Judgement Published
Validated
Assigned finding tags:

finding-PreMarkets-AbortBidTaker-event-offer-stock

Valid low severity, wrong parameter inputted for `AbortBidTaker` event

Support

FAQs

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