Resonance Security reviewed Cube3 on 14 Aug 2024: 2 findings, 0 critical; 1 marked fixed, 1 acknowledged.
Trustblock does not review code.
Statuses are the security firm’s own, from its report.
| Severity | Open | Acknowledged | Fixed |
|---|---|---|---|
| Critical | 0 | 0 | 0 |
| High | 0 | 0 | 0 |
| Medium | 0 | 0 | 0 |
| Low | 0 | 1 | 1 |
Marked Info by the firm. Not counted as findings.
In several places across the codebase, contracts reference addresses of other contracts. A validation is performed that simply verifies whether these addresses are equal to the zero-address. This assures calling only an existing address in the blockchain, however, it does not ensures that this address is able to properly receive the call. Such validation is performed via ERC165's supportsInterface() function which makes sure that a given address implements an expected interface. Additionally, such a validation indirectly asserts that the the given address is a not a zero-address.
OpenZeppelin implements several standards used all across blockchain development, especially in Solidity and the Ethereum Virtual Machine. These standards primary goal is to unify and normalize development patterns so that the entire blockchain may be more understandable and readily usable.The Cube3 smart contracts implement source code that mimics or is very similar to components already implemented by OpenZepellin, and could therefore, be switched with the more the standard well-known approach. Such source code is included in:RouterStorage.sol contract pausability features, can be substituted with OpenZeppellin's implementation of PausableUpgradeable.It should be noted that the usage of bigger libraries does not constitute an overuse of gas, since only the functions that are used are included on the bytecode of the smart contract.
Floating pragmas is a feature of Solidity that allows developers to specify a range of compiler versions that can be used to compile the smart contract code. For security purposes specifically, the usage of floating pragmas is discouraged and not recommended. Contracts should be compiled and deployed with a strict pragma, the one which was thoroughly tested the most by developers. Locking the pragma helps ensure that contracts do not accidentally get deployed using too old or too recent compiler versions that might introduce security issues that impact the contract negatively.It should be noted however that, pragma statements can be allowed to float when a contract is intended for consumption by other developers, as in the case with contracts in a library or EthPM package.The smart contracts of Cube3's core protocol make use of floating pragmas. These are not intended for use as libraries for other developers and, as such, should be locked of their pragma.
The ProtocolManagement contract defines an installModule() function that saves new module's address into the storage. It was observed that it performs a zero-address check that is then followed by ERC165's supportsInterface() verification. Because the ERC165 standard is used, the zero-address check is redundant as the supportsInterface() function will fail if called on the zero-address. Effectively, the zero-address check is performed twice which incurs a higher gas costs.
The report names a repository or files. Open the report to see its scope.
27 projects reviewed · 57 reports · latest Dec 2025
See Resonance Security’s auditsSomething wrong on this page? A missing report, a wrong date, a finding that was fixed since. Tell us and we check it against its source.
Tell us