This document is a security audit report performed by danbogd, where AMO Project has been reviewed.
Сommit hash 329d08712c2555330ec7613df676aa88c9183fdf.
In total, 9 issues were reported including:
- 1 high severity issues
- 1 medium severity issues
- 2 low severity issues
- 4 owner privileges (ability of owner to manipulate contract, may be risky for investors)..
- 1 notes.
No critical security issues were found.
The buy function of AMOCoinSale contract missing a line of code required for transfer purchase tokens for buyer account, but nevertheless TokenPurchase event presents.
The owner or a hacker (if the owner's private key will be compromised) can lock account any user at any time, which will make it impossible to transfer funds. This is dangerous for investors and for exchanges too.
-
It is possible to double withdrawal attack. More details here.
-
Lack of transaction handling mechanism issue. WARNING! This is a very common issue and it already caused millions of dollars losses for lots of token users! More details here.
Add into a function transfer(address _to, ... )
following code:
require( _to != address(this) );
The contract owner allow himself to:
- Evacuate Tokens at any time.
- Missing burn function after crowdsale.
- Enable and disable transfer functions.
- Set rate, hardcap for evry round.
The ether is redirected to address fundAddr. So, one needs to check in advance that this address is not the address of contract. In if case if, for example, address of fundAddr is a contract and its fallback function is implemented as follows: function { throw; }
no purchase transaction will work.
https://github.com/AMO-Project/AMO-Contracts/blob/329d08712c2555330ec7613df676aa88c9183fdf/contracts/AMOCoinSale.sol#L15 https://github.com/AMO-Project/AMO-Contracts/blob/329d08712c2555330ec7613df676aa88c9183fdf/contracts/AMOCoinSale.sol#L388
The contracts use solidity version 0.4.18. It is suggested to use the latest version and fix all compiler warnings that arise. Compiler version should be fixed to avoid any potential discrepancies in smart contract behavior caused by different versions of compiler.
The review did not show any critical issues, some of high, medium and low severity issues were found.