bosonprotocol / boson-protocol-contracts

Boson Protocol V2 (latest)
https://bosonprotocol.io/
GNU General Public License v3.0
32 stars 8 forks source link

Missing reentrancy guard #762

Closed zajck closed 1 year ago

zajck commented 1 year ago

setAllowlistedFunctions is missing the reentrancy guard, which under certain circumstances allows the attacker to impersonate the admin account and modify the allow list.

https://github.com/bosonprotocol/boson-protocol-contracts/blob/9070c0484634cec7bec793808a43ca20616d889a/contracts/protocol/facets/MetaTransactionsHandlerFacet.sol#L339-L342

Recommendation

Add the reentrancy guard.

mischat commented 1 year ago

Good catch here.