<!-- canonical: https://0xsimao.com/findings/ostium-ownable2-step-recommended-ownable -->

# Ownable2Step is recommended over Ownable

Low/Info · Three Sigma · RWA perpetuals DEX · 19th February, 2024

Finding 3S-OS-L9 of the Ostium security review.

- Protocol: https://www.ostium.com/
- Report: /reports/ostium
- Source: https://cdn.sanity.io/files/qoqld077/production/a95b9c69e0f65d1d6b0e649f0d62a362358ca8ce.pdf

---

### Description

Ownable uses a dangerous pattern of setting the address without proper checks. This
means that if a mistake is made and ownership is transferred to the wrong address, the
owner functionalities would be forever lost.

### Recommendation

[Ownable2Step](https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/access/Ownable2Step.sol) eliminates this risk by using a 2 step pattern by setting a pending governor
and having it accept ownership.

### Status

Acknowledged

---

Related findings:

- [Ownable2Step should be preferred over Ownable](https://0xsimao.com/findings/metazero-i-ownable2-step-preferred-ownable): MetaZero Omnichain NFTs
