Omniscia Alliance Block Audit

Manual Review

Manual Review

A thorough line-by-line review was conducted on the codebase to identify potential malfunctions and vulnerabilities in the liquidity staking codebase.

As the project at hand implements staking pools, intricate care was put into ensuring that the flow of funds within the system conforms to the specifications and restrictions laid forth within the protocol's specification.

We validated that all state transitions of the system occur within sane criteria and that all rudimentary formulas within the system execute as expected. We identified 2 major vulnerabilities; the former concerning a full takeover of the LiquidityMiningCampaign contract enabling the malicious party to siphon all the reward token funds from within, and the latter permanently locking user stakes due to a miscalculation on how the AutoStake contracts are restaked into the reward pool.

Additionally, the system was investigated for any other commonly present attack vectors such as re-entrancy attacks, mathematical truncations, logical flaws and ERC / EIP standard inconsistencies. The documentation of the project was satisfactory to a certain extent, however, we strongly recommend the documentation of the project to be expanded at certain complex points such as the autostake and pool features as certain contracts require special attention i.e. derivative implementations of StakeTransferer should impose proper access control and override the setReceiverWhitelisted implementation as the base implementation does not impose any restriction.

A total of 60 findings were identified over the course of the manual review of which 18 findings concerned the behaviour and security of the system. The non-security related findings, such as optimizations, are included in the separate Code Style chapter.

The finding table below enumerates all these security / behavioural findings:

IDSeverityAddressedTitle
APF-01MMinorYesPull-Over-Push Pattern
ASE-01MMajorYesInvalid Restake of Exited Stakes
LMC-01MMajorYesInexistent Access Control of lockSchemes Setter
LMC-02MMediumYesPotentially Inaccurate Proportional Calculation
LMC-03MMinorYesComment Addression
LMC-04MMinorYesInexistent Re-Entrancy Guard
LMF-01MMediumYesPotential for Lock of Funds
LMF-02MMinorNoNon-Standard Pool Seeding
LSE-01MMinorYesUnsanitized LockScheme Configuration
NCP-01MMinorNoNon-Standard Pool Seeding
RPB-01MMediumYesIncorrect Rewards & Multiplier Calculations
RPB-02MMinorYesInsufficient Siphoning Protection
RPF-01MMediumYesPotential for Lock of Funds
RPF-02MMinorNoNon-Standard Pool Seeding
TET-01MMinorNoCode Bottleneck
TET-02MMinorYesInapplicacy of Checks-Effects-Interactions Pattern
TET-03MMinorNoIncorrect Cap Management
TET-04MMinorYesMulti-Transaction Reversal