Platform: Code4rena
Start Date: 18/10/2023
Pot Size: $36,500 USDC
Total HM: 17
Participants: 77
Period: 7 days
Judge: MiloTruck
Total Solo HM: 5
Id: 297
League: ETH
Rank: 19/77
Findings: 3
Award: $300.52
🌟 Selected for report: 0
🚀 Solo Findings: 0
21.9995 USDC - $22.00
Missing functionality prevents ODProxy from granting other accounts access to the safe.
In order to grant access to the particular safe for which specific instance of ODProxy is the owner, it is necessary to call allowSAFE() on ODSafeManager. This method initially can only be invoked by the safe owner or the corresponding instance of ODProxy.
System is designed so that ODProxy uses functionality in BasicActions.sol and CommonActions.sol to interact with the ODSafeManager (by relying on delegatecall). However, current functionality in BasicActions and CommonActions does not contain corresponding functionality for invoking allowSAFE().
Also calling directly ODSafeManager.allowSAFE() through ODProxy does not work since that call would be executed in the context of ODProxy (due to delegatecall invocation).
For users to successfully invoke allowSAFE() they would need to deploy or use some other already deployed contract with extra functionality that wraps interaction with ODSafeManager.allowSAFE(). In this case delegatecall will be properly propagated and updates in ODSafeManager will be properly executed in the context of ODSafeManager and not of ODProxy.
Manual review
Add extra functionality to the BasicActions.sol or document how end users should deploy extra functionality to interact with all ODSafeManager contract features.
call/delegatecall
#0 - c4-pre-sort
2023-10-26T19:31:39Z
raymondfam marked the issue as sufficient quality report
#1 - c4-pre-sort
2023-10-26T19:31:53Z
raymondfam marked the issue as duplicate of #380
#2 - c4-judge
2023-11-02T18:18:32Z
MiloTruck marked the issue as not a duplicate
#3 - c4-judge
2023-11-02T18:18:41Z
MiloTruck marked the issue as duplicate of #294
#4 - c4-judge
2023-11-08T00:24:28Z
MiloTruck marked the issue as satisfactory
224.3342 USDC - $224.33
Updating safeManager reference in Vault721 will brick safe transfers since the state of the new ODSafeManager instance won't have corresponding data. In addition, it is not clear how it would be possible to achieve seamless migration as particular safeHandler instance grants safe modification permission within SafeEngine only to the single/original ODSafeManager instance and cannot be updated afterwards since there is no functionality for that in SafeHandler.sol contract.
It seems that if updates to the implementation are expected ODSafeManager should be a proxy contract.
Manual review.
Consider making ODSafeManager reference in Vault721 immutable. Make ODSafeManager upgradeable contract.
Upgradable
#0 - c4-pre-sort
2023-10-26T19:41:23Z
raymondfam marked the issue as low quality report
#1 - c4-pre-sort
2023-10-26T19:41:41Z
raymondfam marked the issue as duplicate of #37
#2 - c4-judge
2023-11-01T20:31:26Z
MiloTruck marked the issue as not a duplicate
#3 - c4-judge
2023-11-01T20:36:02Z
MiloTruck marked the issue as duplicate of #233
#4 - c4-judge
2023-11-08T00:06:33Z
MiloTruck marked the issue as partial-25
#5 - MiloTruck
2023-11-08T00:07:15Z
Partial credit as the report has highlighted the bug, but didn't provide sufficient explanation as to what the bug is.
#6 - c4-judge
2023-11-08T00:07:37Z
MiloTruck changed the severity to 2 (Med Risk)
#7 - c4-judge
2023-11-08T00:12:15Z
MiloTruck marked the issue as satisfactory
54.1911 USDC - $54.19
Governance system is initialised with 1 block of initial voting delay and 15 blocks for the duration of the voting period. These parameters are inadequate for meaningful governance process as they allow proposals to be created and executed after 3-4 mins on Arbitrum. This short voting period does not allow end users to react in case of undesired system changes, while attackers may potentially compromise system by proposing, voting for, and executing malicious proposal in short time span before others may even notice it.
Based on the values it seems that incorrect assumption is that unit for these params is days while the actual unit is a block.
Following is the initilization of ODGovernor with mentioned parameters.
constructor( address _token, TimelockController _timelock ) Governor('ODGovernor') GovernorSettings(1, 15, 0) GovernorVotes(IVotes(_token)) GovernorVotesQuorumFraction(3) GovernorTimelockControl(_timelock) {}
Manual review
Set initial GovernorSettings parameters to a more meaningful values.
Governance
#0 - c4-pre-sort
2023-10-26T17:56:27Z
raymondfam marked the issue as low quality report
#1 - c4-pre-sort
2023-10-26T17:56:38Z
raymondfam marked the issue as duplicate of #73
#2 - c4-judge
2023-11-02T08:47:11Z
MiloTruck marked the issue as satisfactory