CertiK reviewed Avrora (AVR) on 23 Aug 2023: 10 findings, 0 critical; 4 acknowledged, 6 open.
Report hosted on skynet.certik.com.
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 | 4 | 0 |
| Medium | 0 | 0 | 0 |
| Low | 6 | 0 | 0 |
Performing integer division before multiplication truncates the low bits, losing the precision of calculation. ```solidity=783 _balances[msg.sender] = accountBalance - amount.div(100).mul(91); ``` --- ```solidity=785 _totalSupply -= amount.div(100).mul(91); ``` --- ```solidity=788 transfer(_withdrawalsContractAddress, amount.div(100).mul(9)); ``` ----- Performing integer division before multiplication truncates the low bits, losing the precision of calculation. ```solidity=1515 _balances[msg.sender] = accountBalance - amount.div(100).mul(90); ``` --- ```solidity=1516 _totalSupply -= amount.div(100).mul(90); ``` --- ```solidity=1517 transfer(_PlayToEarn, amount.div(100).mul(10)); ```
Addresses are not validated before assignment or external calls, potentially allowing the use of zero addresses and leading to unexpected behavior or vulnerabilities. For example, transferring tokens to a zero address can result in a permanent loss of those tokens. ```solidity=763 _withdrawalsContractAddress = withdrawalsContractAddress_; ``` - `withdrawalsContractAddress_` is not zero-checked before being used. ```solidity=1482 _PlayToEarn = PlayToEarn; ``` - `PlayToEarn` is not zero-checked before being used.
The `require` check in the `burn()` function is redundant as it checks that `msg.sender` is not the zero address, but in reality, the zero address cannot initialize any transactions or calls.
The `initialize` function in the `mAVRToken` contract is responsible for the initial distribution of tokens to different addresses. However, it should be noted that the `initialize` function is not automatically called immediately after the deployment of the contract. This might lead to a potential front-running issue where a malicious actor can see the transaction that calls `initialize` before it is mined and then tries to take advantage of this situation.
The `SafeMath` library is used unnecessarily. With Solidity compiler versions 0.8.0 or newer, arithmetic operations will automatically revert in case of integer overflow or underflow. ```solidity=18 library SafeMath { ``` - An implementation of `SafeMath` library is found. --- ```solidity=747 using SafeMath for uint256; ``` - `SafeMath` library is used for `uint256` type in `AVR` contract. ```solidity=19 library SafeMath { ``` - An implementation of `SafeMath` library is found. --- ```solidity=1460 using SafeMath for uint256; ``` - `SafeMath` library is used for `uint256` type in `mAVRToken` contract.
Some state variables are not used in the codebase. This can lead to incomplete functionality or potential vulnerabilities if these variables are expected to be utilized. Variable `_decimals` in `AVR` is never used in `AVR`. ```solidity=748 uint8 private _decimals; ``` ```solidity=745 contract AVR is ERC20 { ```
| Address | Chain | Source code |
|---|---|---|
| 0xcfe9…a77f0xcfe90d9fcbee5b4fe05a1723c493483b08b1a77f | Chain: BNB Chain | Source code: Verified source |
| 0x4481…05240x4481a01d7f5c8ec65ce963cb15d5bcfa05110524 | Chain: BNB Chain | Source code: Verified source |
1,045 projects reviewed · 1,376 reports · latest May 2025
See CertiK’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