Lucene search

K
code423n4Code4renaCODE423N4:2022-06-BADGER-FINDINGS-ISSUES-15
HistoryJun 16, 2022 - 12:00 a.m.

Update initializer modifier to prevent reentrancy during initialization

2022-06-1600:00:00
Code4rena
github.com
4

Lines of code
<https://github.com/Badger-Finance/vested-aura/blob/d504684e4f9b56660a9e6c6dfb839dcebac3c174/brownie-config.yaml#L19&gt;
<https://github.com/Badger-Finance/vested-aura/blob/d504684e4f9b56660a9e6c6dfb839dcebac3c174/contracts/MyStrategy.sol#L56&gt;

Vulnerability details

#Proof of Concept
<https://github.com/Badger-Finance/vested-aura/blob/d504684e4f9b56660a9e6c6dfb839dcebac3c174/brownie-config.yaml#L19&gt;

The code uses:
@openzeppelin-contracts-upgradeable=OpenZeppelin/[email protected]/contracts/

This dependency have a known high severity vulnerability:

Which makes the main contract in this audit β€œMyStrategy” vulnerable during initialization:
<https://github.com/Badger-Finance/vested-aura/blob/d504684e4f9b56660a9e6c6dfb839dcebac3c174/contracts/MyStrategy.sol#L56&gt;

Recommended Mitigation Steps

Upgrade @openzeppelin/contracts-upgradeable to version 4.4.1 or higher.
(and upgrade @openzeppelin/contracts to version 4.4.1 or higher, if in use elsewhere)


The text was updated successfully, but these errors were encountered:

All reactions