Paladin - Warden Pledges contest - yixxas's results

A governance lending protocol transforming users voting power into a new money lego.

General Information

Platform: Code4rena

Start Date: 27/10/2022

Pot Size: $33,500 USDC

Total HM: 8

Participants: 96

Period: 3 days

Judge: kirk-baird

Total Solo HM: 1

Id: 176

League: ETH

Paladin

Findings Distribution

Researcher Performance

Rank: 57/96

Findings: 2

Award: $24.59

QA:
grade-b

🌟 Selected for report: 0

🚀 Solo Findings: 0

Awards

4.9536 USDC - $4.95

Labels

2 (Med Risk)
partial-50
duplicate-68

External Links

Judge has assessed an item in Issue #43 as M risk. The relevant finding follows:

Q-02 - Huge trust assumption in recoverErc20() https://github.com/code-423n4/2022-10-paladin/blob/d6d0c0e57ad80f15e9691086c9c7270d4ccfe0e6/contracts/WardenPledge.sol#L653-L661

Reward tokens are transferred into this contract when a pledge is created. The comment notes " Recovers ERC2O tokens sent by mistake to the contract", but this function can also be used by the owner to draw and drain all tokens that are deposited by pledge creators.

The cons of this function far outweighs the benefit, hence I recommend removing this function.

#0 - c4-judge

2022-11-11T23:49:06Z

kirk-baird marked the issue as duplicate of #17

#1 - c4-judge

2022-11-11T23:49:11Z

kirk-baird marked the issue as partial-50

#2 - c4-judge

2022-12-06T17:32:42Z

Simon-Busch marked the issue as duplicate of #68

Q-01 - Check for 0 addresses not done in constructor

https://github.com/code-423n4/2022-10-paladin/blob/d6d0c0e57ad80f15e9691086c9c7270d4ccfe0e6/contracts/WardenPledge.sol#L131-L143

The 0 addresses check are done in the respective update() functions but not done in constructor. In fact, it is important to ensure that the chestAddress is not accidentally set to the 0 address as fees are transferred to it and funds can be lost forever. There is also no way to update the votingEscrow and delegationBoost address.

Q-02 - Huge trust assumption in recoverErc20()

https://github.com/code-423n4/2022-10-paladin/blob/d6d0c0e57ad80f15e9691086c9c7270d4ccfe0e6/contracts/WardenPledge.sol#L653-L661

Reward tokens are transferred into this contract when a pledge is created. The comment notes " Recovers ERC2O tokens sent by mistake to the contract", but this function can also be used by the owner to draw and drain all tokens that are deposited by pledge creators.

The cons of this function far outweighs the benefit, hence I recommend removing this function.

#0 - c4-judge

2022-11-11T23:49:19Z

kirk-baird marked the issue as grade-b

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