Open c4-submissions opened 1 year ago
raymondfam marked the issue as low quality report
raymondfam marked the issue as duplicate of #41
gzeon-c4 changed the severity to QA (Quality Assurance)
gzeon-c4 marked the issue as grade-c
gzeon-c4 marked the issue as grade-b
Lines of code
https://github.com/code-423n4/2023-09-centrifuge/blob/0af232255c7d045efde4ac40801dfeeed8a8d889/src/LiquidityPool.sol#L98
Vulnerability details
Impact
withApproval in LiquidityManager.sol has the documentation
However, the code makes it very clear that only owners have approval, never wards.
The upshot is that only owners of positions can modify them. Wards cannot, even though the documentation makes it clear they should be able to.
Proof of Concept
I modified testDepositWithApproval in Liquidity.t.sol to try the deposit where the test contract is a ward.
However, the transaction reverted with "LiquidityPool/no-approval", even though the caller is a ward and should have this power according to the docs.
Tools Used
Manuel inspection
Recommended Mitigation Steps
Assessed type
Access Control