Niob Finance is a Decentralized Exchange and Automatic Liquidity Acquisition Yield Farm, with a three-level referral system. Niob currently runs on BSC and has an aim to launch on several other blockchains in the future. The project utilizes deflationary token NIOB. Each time the token is transferred – it triggers the auto-burn mechanism. Another unique feature of NIOB token is ability to allocate part of transfer tax towards the locked liquidity.
The innovative products and features which Niob’s team will be delivering as per Niob’s roadmap, should provide a sustainable environment for users to benefit from high APR yield farming and many other DeFi solutions, such as prediction trading, NFT platform, and non-custodial crypto wallet with fiat getaway.
NiobToken.addLiquidity(uint256,uint256) (#1406-1419) sends eth to arbitrary user
Dangerous calls:
- NiobSwapRouter.addLiquidityETH{value: ethAmount}(address(this),tokenAmount,0,0,operator(),block.timestamp) (#1411-1418)
Ensure that an arbitrary user cannot withdraw unauthorized funds.
Additional information: link
Reentrancy in NiobToken._transfer(address,address,uint256) (#1316-1351):
External calls:
- swapAndLiquify() (#1326)
- NiobSwapRouter.addLiquidityETH{value: ethAmount}(address(this),tokenAmount,0,0,operator(),block.timestamp) (#1411-1418)
- NiobSwapRouter.swapExactTokensForETHSupportingFeeOnTransferTokens(tokenAmount,0,path,address(this),block.timestamp) (#1396-1402)
External calls sending eth:
- swapAndLiquify() (#1326)
- NiobSwapRouter.addLiquidityETH{value: ethAmount}(address(this),tokenAmount,0,0,operator(),block.timestamp) (#1411-1418)
State variables written after the call(s):
- super._transfer(sender,recipient,amount) (#1330)
- _balances[sender] = _balances[sender].sub(amount,BEP20: transfer amount exceeds balance) (#1115)
- _balances[recipient] = _balances[recipient].add(amount) (#1116)
- super._transfer(sender,BURN_ADDRESS,burnAmount) (#1344)
- _balances[sender] = _balances[sender].sub(amount,BEP20: transfer amount exceeds balance) (#1115)
- _balances[recipient] = _balances[recipient].add(amount) (#1116)
- super._transfer(sender,address(this),liquidityAmount) (#1345)
- _balances[sender] = _balances[sender].sub(amount,BEP20: transfer amount exceeds balance) (#1115)
- _balances[recipient] = _balances[recipient].add(amount) (#1116)
- super._transfer(sender,reserveAddress,reserveAmount) (#1346)
- _balances[sender] = _balances[sender].sub(amount,BEP20: transfer amount exceeds balance) (#1115)
- _balances[recipient] = _balances[recipient].add(amount) (#1116)
- super._transfer(sender,devAddress,devAmount) (#1347)
- _balances[sender] = _balances[sender].sub(amount,BEP20: transfer amount exceeds balance) (#1115)
- _balances[recipient] = _balances[recipient].add(amount) (#1116)
- super._transfer(sender,recipient,sendAmount) (#1348)
- _balances[sender] = _balances[sender].sub(amount,BEP20: transfer amount exceeds balance) (#1115)
- _balances[recipient] = _balances[recipient].add(amount) (#1116)
Apply the check-effects-interactions pattern.
Additional information: link
NiobToken._writeCheckpoint(address,uint32,uint256,uint256) (#1759-1777) uses a dangerous strict equality:
- nCheckpoints > 0 && checkpoints[delegatee][nCheckpoints - 1].fromBlock == blockNumber (#1769)
Don't use strict equality to determine if an account has enough Ether or tokens.
Additional information: link
Combination 1: Reentrancy vulnerabilities + Functions that send Ether to arbitraty destination. Usual for scams. May be justified by some complex mechanics (e.g. rebase, reflections). DYOR & manual audit are advised.
NiobToken.updateLiquidityRate(uint16) (#1462-1465) should emit an event for:
- liquidityRate = _liquidityRate (#1464)
NiobToken.updateReserveRate(uint16) (#1471-1474) should emit an event for:
- reserveRate = _reserveRate (#1473)
Emit an event for critical parameter changes.
Additional information: link
NiobToken.addLiquidity(uint256,uint256) (#1406-1419) ignores return value by NiobSwapRouter.addLiquidityETH{value: ethAmount}(address(this),tokenAmount,0,0,operator(),block.timestamp) (#1411-1418)
Ensure that all the return values of the function calls are used.
Additional information: link
BEP20.constructor(string,string).name (#934) shadows:
- BEP20.name() (#950-952) (function)
- IBEP20.name() (#695) (function)
BEP20.constructor(string,string).symbol (#934) shadows:
- BEP20.symbol() (#964-966) (function)
- IBEP20.symbol() (#690) (function)
BEP20.allowance(address,address).owner (#998) shadows:
- Ownable.owner() (#833-835) (function)
BEP20._approve(address,address,uint256).owner (#1170) shadows:
- Ownable.owner() (#833-835) (function)
NiobToken.swapAndLiquify().maxTransferAmount (#1356) shadows:
- NiobToken.maxTransferAmount() (#1424-1426) (function)
Rename the local variables that shadow another component.
Additional information: link
NiobToken._transfer(address,address,uint256) (#1316-1351) performs a multiplication on the result of a division:
-taxAmount = amount.mul(transferTaxRate).div(10000) (#1333)
-burnAmount = taxAmount.mul(burnRate).div(100) (#1334)
NiobToken._transfer(address,address,uint256) (#1316-1351) performs a multiplication on the result of a division:
-taxAmount = amount.mul(transferTaxRate).div(10000) (#1333)
-liquidityAmount = taxAmount.mul(liquidityRate).div(100) (#1335)
NiobToken._transfer(address,address,uint256) (#1316-1351) performs a multiplication on the result of a division:
-taxAmount = amount.mul(transferTaxRate).div(10000) (#1333)
-reserveAmount = taxAmount.mul(reserveRate).div(100) (#1336)
Consider ordering multiplication before division.
Additional information: link
NiobToken.constructor(address,address)._dev (#1293) lacks a zero-check on :
- devAddress = _dev (#1297)
NiobToken.constructor(address,address)._reserve (#1293) lacks a zero-check on :
- reserveAddress = _reserve (#1298)
Check that the address is not zero.
Additional information: link
Reentrancy in NiobToken.swapAndLiquify() (#1354-1384):
External calls:
- swapTokensForEth(half) (#1374)
- NiobSwapRouter.swapExactTokensForETHSupportingFeeOnTransferTokens(tokenAmount,0,path,address(this),block.timestamp) (#1396-1402)
- addLiquidity(otherHalf,newBalance) (#1380)
- NiobSwapRouter.addLiquidityETH{value: ethAmount}(address(this),tokenAmount,0,0,operator(),block.timestamp) (#1411-1418)
External calls sending eth:
- addLiquidity(otherHalf,newBalance) (#1380)
- NiobSwapRouter.addLiquidityETH{value: ethAmount}(address(this),tokenAmount,0,0,operator(),block.timestamp) (#1411-1418)
State variables written after the call(s):
- addLiquidity(otherHalf,newBalance) (#1380)
- _allowances[owner][spender] = amount (#1177)
Apply the check-effects-interactions pattern.
Additional information: link
Reentrancy in NiobToken._transfer(address,address,uint256) (#1316-1351):
External calls:
- swapAndLiquify() (#1326)
- NiobSwapRouter.addLiquidityETH{value: ethAmount}(address(this),tokenAmount,0,0,operator(),block.timestamp) (#1411-1418)
- NiobSwapRouter.swapExactTokensForETHSupportingFeeOnTransferTokens(tokenAmount,0,path,address(this),block.timestamp) (#1396-1402)
External calls sending eth:
- swapAndLiquify() (#1326)
- NiobSwapRouter.addLiquidityETH{value: ethAmount}(address(this),tokenAmount,0,0,operator(),block.timestamp) (#1411-1418)
Event emitted after the call(s):
- Transfer(sender,recipient,amount) (#1117)
- super._transfer(sender,recipient,amount) (#1330)
- Transfer(sender,recipient,amount) (#1117)
- super._transfer(sender,reserveAddress,reserveAmount) (#1346)
- Transfer(sender,recipient,amount) (#1117)
- super._transfer(sender,address(this),liquidityAmount) (#1345)
- Transfer(sender,recipient,amount) (#1117)
- super._transfer(sender,BURN_ADDRESS,burnAmount) (#1344)
- Transfer(sender,recipient,amount) (#1117)
- super._transfer(sender,devAddress,devAmount) (#1347)
- Transfer(sender,recipient,amount) (#1117)
- super._transfer(sender,recipient,sendAmount) (#1348)
Reentrancy in NiobToken.swapAndLiquify() (#1354-1384):
External calls:
- swapTokensForEth(half) (#1374)
- NiobSwapRouter.swapExactTokensForETHSupportingFeeOnTransferTokens(tokenAmount,0,path,address(this),block.timestamp) (#1396-1402)
- addLiquidity(otherHalf,newBalance) (#1380)
- NiobSwapRouter.addLiquidityETH{value: ethAmount}(address(this),tokenAmount,0,0,operator(),block.timestamp) (#1411-1418)
External calls sending eth:
- addLiquidity(otherHalf,newBalance) (#1380)
- NiobSwapRouter.addLiquidityETH{value: ethAmount}(address(this),tokenAmount,0,0,operator(),block.timestamp) (#1411-1418)
Event emitted after the call(s):
- Approval(owner,spender,amount) (#1178)
- addLiquidity(otherHalf,newBalance) (#1380)
- SwapAndLiquify(half,newBalance,otherHalf) (#1382)
Apply the check-effects-interactions pattern.
Additional information: link
NiobToken.delegateBySig(address,uint256,uint256,uint8,bytes32,bytes32) (#1625-1666) uses timestamp for comparisons
Dangerous comparisons:
- require(bool,string)(block.timestamp <= expiry,Niob::delegateBySig: signature expired) (#1664)
Avoid relying on block.timestamp.
Additional information: link
Address.isContract(address) (#248-258) uses assembly
- INLINE ASM (#254-256)
Address.verifyCallResult(bool,bytes,string) (#417-437) uses assembly
- INLINE ASM (#429-432)
NiobToken.getChainId() (#1784-1791) uses assembly
- INLINE ASM (#1786-1789)
Do not use evm assembly.
Additional information: link
NiobToken._transfer(address,address,uint256) (#1316-1351) compares to a boolean constant:
-swapAndLiquifyEnabled == true && _inSwapAndLiquify == false && address(NiobSwapRouter) != address(0) && NiobSwapPair != address(0) && sender != NiobSwapPair && sender != owner() (#1319-1324)
NiobToken.antiWhale(address,address,uint256) (#1265-1275) compares to a boolean constant:
-_excludedFromAntiWhale[sender] == false && _excludedFromAntiWhale[recipient] == false (#1268-1269)
Remove the equality to the boolean constant.
Additional information: link
Different versions of Solidity is used:
- Version used: ['>=0.4.0', '>=0.5.0', '>=0.6.12', '>=0.6.2', '^0.8.0']
- >=0.5.0 (#3)
- >=0.5.0 (#23)
- >=0.6.2 (#78)
- >=0.6.2 (#176)
- ^0.8.0 (#225)
- ^0.8.0 (#445)
- >=0.4.0 (#674)
- ^0.8.0 (#776)
- ^0.8.0 (#803)
- >=0.4.0 (#880)
- >=0.6.12 (#1201)
Use one Solidity version.
Additional information: link
Address.functionCall(address,bytes) (#301-303) is never used and should be removed
Address.functionCall(address,bytes,string) (#311-317) is never used and should be removed
Address.functionCallWithValue(address,bytes,uint256) (#330-336) is never used and should be removed
Address.functionCallWithValue(address,bytes,uint256,string) (#344-355) is never used and should be removed
Address.functionDelegateCall(address,bytes) (#390-392) is never used and should be removed
Address.functionDelegateCall(address,bytes,string) (#400-409) is never used and should be removed
Address.functionStaticCall(address,bytes) (#363-365) is never used and should be removed
Address.functionStaticCall(address,bytes,string) (#373-382) is never used and should be removed
Address.isContract(address) (#248-258) is never used and should be removed
Address.sendValue(address,uint256) (#276-281) is never used and should be removed
Address.verifyCallResult(bool,bytes,string) (#417-437) is never used and should be removed
BEP20._burn(address,uint256) (#1148-1154) is never used and should be removed
BEP20._burnFrom(address,uint256) (#1187-1194) is never used and should be removed
Context._msgData() (#793-795) is never used and should be removed
SafeMath.div(uint256,uint256,string) (#632-641) is never used and should be removed
SafeMath.mod(uint256,uint256) (#592-594) is never used and should be removed
SafeMath.mod(uint256,uint256,string) (#658-667) is never used and should be removed
SafeMath.tryAdd(uint256,uint256) (#463-469) is never used and should be removed
SafeMath.tryDiv(uint256,uint256) (#505-510) is never used and should be removed
SafeMath.tryMod(uint256,uint256) (#517-522) is never used and should be removed
SafeMath.tryMul(uint256,uint256) (#488-498) is never used and should be removed
SafeMath.trySub(uint256,uint256) (#476-481) is never used and should be removed
Remove unused functions.
Additional information: link
Pragma version>=0.5.0 (#3) allows old versions
Pragma version>=0.5.0 (#23) allows old versions
Pragma version>=0.6.2 (#78) allows old versions
Pragma version>=0.6.2 (#176) allows old versions
Pragma version^0.8.0 (#225) allows old versions
Pragma version^0.8.0 (#445) allows old versions
Pragma version>=0.4.0 (#674) allows old versions
Pragma version^0.8.0 (#776) allows old versions
Pragma version^0.8.0 (#803) allows old versions
Pragma version>=0.4.0 (#880) allows old versions
solc-0.8.11 is not recommended for deployment
Deploy with any of the following Solidity versions: 0.5.16 - 0.5.17, 0.6.11 - 0.6.12, 0.7.5 - 0.7.6 Use a simple pragma version that allows any of these versions. Consider using the latest version of Solidity for testing.
Additional information: link
Low level call in Address.sendValue(address,uint256) (#276-281):
- (success) = recipient.call{value: amount}() (#279)
Low level call in Address.functionCallWithValue(address,bytes,uint256,string) (#344-355):
- (success,returndata) = target.call{value: value}(data) (#353)
Low level call in Address.functionStaticCall(address,bytes,string) (#373-382):
- (success,returndata) = target.staticcall(data) (#380)
Low level call in Address.functionDelegateCall(address,bytes,string) (#400-409):
- (success,returndata) = target.delegatecall(data) (#407)
Avoid low-level calls. Check the call success. If the call is meant for a contract, check for code existence
Additional information: link
Function IUniswapV2Pair.DOMAIN_SEPARATOR() (#40) is not in mixedCase
Function IUniswapV2Pair.PERMIT_TYPEHASH() (#41) is not in mixedCase
Function IUniswapV2Pair.MINIMUM_LIQUIDITY() (#58) is not in mixedCase
Function IUniswapV2Router01.WETH() (#82) is not in mixedCase
Parameter NiobToken.mint(address,uint256)._to (#1309) is not in mixedCase
Parameter NiobToken.mint(address,uint256)._amount (#1309) is not in mixedCase
Parameter NiobToken.isExcludedFromAntiWhale(address)._account (#1431) is not in mixedCase
Parameter NiobToken.updateTransferTaxRate(uint16)._transferTaxRate (#1442) is not in mixedCase
Parameter NiobToken.updateBurnRate(uint16)._burnRate (#1452) is not in mixedCase
Parameter NiobToken.updateLiquidityRate(uint16)._liquidityRate (#1462) is not in mixedCase
Parameter NiobToken.updateReserveRate(uint16)._reserveRate (#1471) is not in mixedCase
Parameter NiobToken.updateMaxTransferAmountRate(uint16)._maxTransferAmountRate (#1480) is not in mixedCase
Parameter NiobToken.updateMinAmountToLiquify(uint256)._minAmount (#1490) is not in mixedCase
Parameter NiobToken.setExcludedFromAntiWhale(address,bool)._account (#1499) is not in mixedCase
Parameter NiobToken.setExcludedFromAntiWhale(address,bool)._excluded (#1499) is not in mixedCase
Parameter NiobToken.updateReserveAddress(address)._reserve (#1507) is not in mixedCase
Parameter NiobToken.updateDevAddress(address)._dev (#1517) is not in mixedCase
Parameter NiobToken.updateSwapAndLiquifyEnabled(bool)._enabled (#1527) is not in mixedCase
Parameter NiobToken.updateNiobSwapRouter(address)._router (#1536) is not in mixedCase
Variable NiobToken.NiobSwapRouter (#1241) is not in mixedCase
Variable NiobToken.NiobSwapPair (#1243) is not in mixedCase
Variable NiobToken._delegates (#1567) is not in mixedCase
Follow the Solidity naming convention.
Additional information: link
Variable IUniswapV2Router01.addLiquidity(address,address,uint256,uint256,uint256,uint256,address,uint256).amountADesired (#87) is too similar to IUniswapV2Router01.addLiquidity(address,address,uint256,uint256,uint256,uint256,address,uint256).amountBDesired (#88)
Prevent variables from having similar names.
Additional information: link
NiobToken.slitherConstructorConstantVariables() (#1211-1793) uses literals with too many digits:
- MAXIMUM_TOTAL_SUPPLY = 600000000000000000000000000 (#1214)
NiobToken.slitherConstructorConstantVariables() (#1211-1793) uses literals with too many digits:
- BURN_ADDRESS = 0x000000000000000000000000000000000000dEaD (#1230)
Use: Ether suffix, Time suffix, or The scientific notation
Additional information: link
renounceOwnership() should be declared external:
- Ownable.renounceOwnership() (#852-854)
transferOwnership(address) should be declared external:
- Ownable.transferOwnership(address) (#860-863)
decimals() should be declared external:
- BEP20.decimals() (#957-959)
symbol() should be declared external:
- BEP20.symbol() (#964-966)
transfer(address,uint256) should be declared external:
- BEP20.transfer(address,uint256) (#990-993)
allowance(address,address) should be declared external:
- BEP20.allowance(address,address) (#998-1000)
approve(address,uint256) should be declared external:
- BEP20.approve(address,uint256) (#1009-1012)
transferFrom(address,address,uint256) should be declared external:
- BEP20.transferFrom(address,address,uint256) (#1026-1038)
increaseAllowance(address,uint256) should be declared external:
- BEP20.increaseAllowance(address,uint256) (#1052-1055)
decreaseAllowance(address,uint256) should be declared external:
- BEP20.decreaseAllowance(address,uint256) (#1071-1078)
mint(uint256) should be declared external:
- BEP20.mint(uint256) (#1088-1091)
mint(address,uint256) should be declared external:
- NiobToken.mint(address,uint256) (#1309-1313)
isExcludedFromAntiWhale(address) should be declared external:
- NiobToken.isExcludedFromAntiWhale(address) (#1431-1433)
updateTransferTaxRate(uint16) should be declared external:
- NiobToken.updateTransferTaxRate(uint16) (#1442-1446)
updateBurnRate(uint16) should be declared external:
- NiobToken.updateBurnRate(uint16) (#1452-1456)
updateLiquidityRate(uint16) should be declared external:
- NiobToken.updateLiquidityRate(uint16) (#1462-1465)
updateReserveRate(uint16) should be declared external:
- NiobToken.updateReserveRate(uint16) (#1471-1474)
updateMaxTransferAmountRate(uint16) should be declared external:
- NiobToken.updateMaxTransferAmountRate(uint16) (#1480-1484)
updateMinAmountToLiquify(uint256) should be declared external:
- NiobToken.updateMinAmountToLiquify(uint256) (#1490-1493)
setExcludedFromAntiWhale(address,bool) should be declared external:
- NiobToken.setExcludedFromAntiWhale(address,bool) (#1499-1501)
updateReserveAddress(address) should be declared external:
- NiobToken.updateReserveAddress(address) (#1507-1511)
updateDevAddress(address) should be declared external:
- NiobToken.updateDevAddress(address) (#1517-1521)
updateSwapAndLiquifyEnabled(bool) should be declared external:
- NiobToken.updateSwapAndLiquifyEnabled(bool) (#1527-1530)
updateNiobSwapRouter(address) should be declared external:
- NiobToken.updateNiobSwapRouter(address) (#1536-1541)
transferOperator(address) should be declared external:
- NiobToken.transferOperator(address) (#1554-1558)
Use the external attribute for functions never called from the contract.
Additional information: link
Young tokens have high risks of price dump / death
Young tokens have high risks of scam / price dump / death
Young tokens have high risks of scam / price dump / death
Young tokens have high risks of price dump / death
Young tokens have high risks of price dump / death
Token has relatively low CoinGecko rank
Token has relatively low CoinMarketCap rank
Unable to find Youtube account