Holograph contest - louhk's results

Omnichain protocol for deploying, minting, & bridging NFTs between blockchains.

General Information

Platform: Code4rena

Start Date: 18/10/2022

Pot Size: $75,000 USDC

Total HM: 27

Participants: 144

Period: 7 days

Judge: gzeon

Total Solo HM: 13

Id: 170

League: ETH

Holograph

Findings Distribution

Researcher Performance

Rank: 135/144

Findings: 1

Award: $0.00

QA:
grade-c

🌟 Selected for report: 0

πŸš€ Solo Findings: 0

Unsafe use of transfer()/transferFrom().

Some tokens do not implement the ERC20 standard properly but are still accepted by most code that accepts ERC20 tokens.

From the below code, the function seems used to transfer token and using transform() function. Some implementations of transfer and transferFrom could return β€˜false’ on failure instead of reverting.

HolographOperator.sol

https://github.com/code-423n4/2022-10-holograph/blob/f8c2eae866280a1acfdc8a8352401ed031be1373/contracts/HolographOperator.sol#:L398-L400

if (leftovers > 0) { _bondedAmounts[job.operator] = 0; _utilityToken().transfer(job.operator, leftovers); }

PA1D.sol

https://github.com/code-423n4/2022-10-holograph/blob/f8c2eae866280a1acfdc8a8352401ed031be1373/contracts/enforcer/PA1D.sol#L394-L396

for (uint256 i = 0; i < length; i++) { sending = ((bps[i] * balance) / 10000); addresses[i].transfer(sending); // sent = sent + sending; }

It is suggested to check the return value and revert on false or use safeERC20 (SafeTransferFrom) function instead of transfer

AuditHub

A portfolio for auditors, a security profile for protocols, a hub for web3 security.

Built bymalatrax Β© 2024

Auditors

Browse

Contests

Browse

Get in touch

ContactTwitter