Closed zerongt9 closed 1 year ago
@zerongt9 The audit fee is 2400 USDT. You may send USDT (ERC20 or BEP20) to: 0x6317c6944bd1cD3932d062cce39d7Fd602119529 (valid for Ethereum and Binance Smart Chain)
The estimated auditing time - is 7 days after payment.
@yuriy77k here is the payment tx hash 0xc40539d299ea0b68a9cbbd001e8d90f4b5fad85846253a2e084eb03f43b8a718
@zerongt9 audit started
@yuriy77k are there any feedback / result?
@zerongt9 The final report will be ready in 2 days.
@zerongt9 We found a medium severity issue in the contract and the report was sent to your email.
we have fixed the issue and pushed to the same repo please help to arrange the re-audit
Live4well smart contract security audit report performed by Callisto Security Audit Department
This is re-audit of smart contracts that were fixed by developer according our recommendation.
Commit 467a0fcbc46b2cc94d9ae9ce63d6d565f318a2eb
In total, 0 issues were reported, including:
0 high severity issues.
0 medium severity issues.
0 low severity issues.
In total, 12 notes were reported, including:
2 minor observations.
10 owner privileges.
The ERC721-nftpass.sol
and MintManager.sol
contract inherits features of the OpenZeppelin AccessControl contract, allowing the administrator to manage administrators. This role can be abandoned, and it will result in blocking access to critical functions of the contract.
safeMint
function allows any user with MINT_ROLE
permissions to mint an unlimited number of NFTs.addMinter
function allows the administrator to grant NFT minter role to any address.setBaseURI
allows the owner to modify the baseURI_
of the NFT tokens.setTokenURI()
allows owner to override the baseURI_
of NFT tokens to custom URI.privateMint
function, allows any address with PRIVATE_MINT
rights, to min any number of NFTs for free, depending on the quota.changeLevelPeriod
function, allows the administrator to change the time range for a mintchangeLevelquota
, allows the administrator to change the quota for the NFT mintaddNewERC20Price
, allows the administrator to add any ERC20 tokens including poisoned tokens as payment for NFTssetPrivateMintRole
, allows the administrator to give rights to any address to allow private minting.transferERC20Token
function allows the administrator to sign out any tokens from the contract.Since the owner has unlimited rights to do everything, the ownership must be transferred to a multi-sig contract. And also the addresses to whom the rights PRIVATE_MINT
, MINT_ROLE
are given must be trusted.
The functions initializeNFTLevelInfo()
and addNewERC20Price()
are used by the owner to set the price of ERC-721 tokens in ERC-20 tokens. For non-stable coins, the value might fluctuate and the prices are required to be updated in case of a change in value. Allowing users to mint the ERC-721 token at an increased or decreased value depending on the price fluctuation.
Consider using a price oracle to get the current value of the ERC-20 tokens and convert the value to a stablecoin to determine the amount of ERC-20 tokens required to mint an NFT by a user.
Contracts should be deployed using the same compiler version/flags with which they have been tested. Locking the floating pragma, i.e. by not using ^ in pragma solidity ^0.8.4, ensures that contracts do not accidentally get deployed using a compiler version with unfixed bugs.
The contracts in the code base lack documentation. This hinders reviewers’ understanding of the code’s intention, which is fundamental to correctly assess not only security but also correctness. Additionally, docstrings improve readability and ease maintenance. They should explicitly explain the purpose or intention of the functions, the scenarios under which they can fail, the roles allowed to call them, the values returned, and the events emitted.
Consider thoroughly documenting all functions (and their parameters) that are part of the contracts’ public API. Functions implementing sensitive functionality, even if not public, should be documented as well. When writing docstrings, consider following the Ethereum Natural Specification Format (NatSpec).
The contract is missing a test suite to validate and verify the behavior of the contract functionalities. Add tests are recommended to ensure that the contract functions and behaves as expected.
CREATE (0xf0)
opcode is assigned following this scheme keccak256(rlp([sender, nonce]))
. Therefore you need to use the same address that was originally used at the main chain to deploy the mock contract at a transaction with the nonce
that matches that on the original chain. Example: If you have deployed your main contract with address 0x010101 at your 2021th transaction then you need to increase your nonce of 0x010101 address to 2020 at the chain where your mock contract will be deployed. Then you can deploy your mock contract with your 2021th transaction, and it will receive the same address as your mainnet contract.The audited smart contract can be deployed. No security issues were found during the audit.
Users should pay attention to unlimited owner's rights.
It is recommended to adhere to the security practices described in pt. 4 of this report to ensure the contract's operability and prevent any issues that are not directly related to the code of this smart contract.
Audit request
Here is two contract related
Source code
https://github.com/technine-IT/live4well-smartcontract-for-audit
Payment plan
... Write [x] at the checkbox of the payment plan that suits your needs ...
Disclosure policy
... Do you want us to publish the report as it is or to notify you privately in case of finding critical mistakes? ...
... provide your conditions for publishing the report or leave only standard disclosure policy link ...
Standard disclosure policy.
Contact information (optional)
slack or email : zero.ng@technine.io
Platform
polygon