Pumptopia

Smart Contract Audit Report

Audit Summary

Pumptopia Audit Report Pumptopia is building a new ERC-20 token on the Ethereum Blockchain that pays out static rewards to holders.

For this audit, we reviewed Pumptopia's token contract at 0x3a67430AeE293A216F9963E3F19C06Ae15824bF0 on the Ethereum Mainnet.

Audit Findings

Please ensure trust in the team prior to investing as they have substantial control in the ecosystem.
Date: March 31st, 2022.

Finding #1 - Pumptopia - Low

Description: The owner can use the lock() function to temporarily set ownership to address(0). Ownership is restored after the duration of time determined by the owner has passed and they use the unlock() function.
Risk/Impact: The unlock function has the potential to be used after ownership has been set to address(0), which will restore ownership to the original owner that initially created the ownership lock. This can be used in a nefarious way by the project team to restore ownership and change fee structures.
Recommendation: We recommend that the unlock function be modified to set the previous owner variable equal to address(0) at the end of the unlock function to prevent it from being used more than once per lock.
Resolution: The team has not yet addressed this issue.

Finding #2 - Pumptopia - Informational

Description: Several functions are declared public, but are never called internally.
 Pumptopia.setFree(), Pumptopia.unSetFree(), Pumptopia.transfer(), Pumptopia.allowance(), Pumptopia.approve(), Pumptopia.setAutomatedMarketMakerPair(), Pumptopia.transferFrom(), Pumptopia.increaseAllowance(), Pumptopia.decreaseAllowance(), Pumptopia.isExcluded(), Pumptopia.deliver(), Pumptopia.reflectionFromToken(), Pumptopia.isExcludedFromFee()
Recommendation: These functions should be declared external for additional gas savings on each call.

Contract Overview

  • The total supply of the token is set to 10 Million $PTPA [10,000,000].
  • No mint or burn functions exist, though the circulating supply can be decreased by sending tokens to the 0x..dead address.
  • At the time of writing this report, there are 325 total token holders. The token allocation is as follows:
    • 21.3% of the total supply belongs to the Owner.
    • 20.8% of the total supply is in the 0x..dead address.
    • 17.8% of the total supply is in Uniswap liquidity.
    • Of that liquidity, 89% is stored in a token locking contract and will fully vest to the Owner at 17:04 on April 1st, 2023 UTC.
    • 6.8% is stored in a token locking contract with an unknown vesting date.
    • 3.6% belongs to the Owner.
    • 3.6% of the total supply belongs to an unverified contract
    • The next five holders own a cumulative 9.2% of the total supply.

  • There is a 5% Tax fee and a 5% Team fee on all transfers where neither the sender nor the recipient is excluded from fees.
  • The tokens collected through the Tax fee are are removed from the circulating supply; This serves as a frictionless fee redistribution which automatically benefits all token holders at the time of each transaction.
  • The tokens collected through the Team fee are stored in the contract address. The tokens are swapped for ETH when the following conditions are met:
    • The automatic token swapping functionality is enabled by the team.
    • The threshold number of 5 tokens in the contract address has been reached.
    • The contract is not currently swapping tokens for ETH.
    • The user is performing a sell transaction via Uniswap.
  • The ETH received through this process is split between two Fee wallets controlled by the team.
  • The contract enforces a maximum transaction amount which imposes a limit to the number of tokens that can be bought via Uniswap during any given transaction.
  • The contract enforces a maximum wallet amount that prevents a transfer from occurring if the recipient's token balance will exceed the limit number of tokens after the transfer occurs.

  • The Owner can manually swap the tokens in the contract address for ETH and send it to the team's Fee wallets at any time.
  • The Owner can set any address as exempt or nonexempt from maximum wallet amounts and transfer amounts at any time.
  • The Owner can set the swap threshold to any value over 5,000 at any time.
  • The team should exercise caution when setting the swap threshold to not exceed the maximum wallet size as this may lead to a denial of service.
  • The Owner can exclude and include accounts from transfer fees and reward distribution at any time.
  • The Owner can modify the Tax fee and Team fee to any percentage between 0% and 25% at any time.
  • The Owner can update the maximum transaction amount and maximum wallet amount to any value at any time.
  • The Owner can update the team's Team wallets to any address at any time.
  • The Owner can set or remove any address as an automated market maker pair at any time.

Audit Results

Vulnerability CategoryNotesResult
Arbitrary Jump/Storage WriteN/APASS
Centralization of Control89% of the LP will unlock to the Owner at 17:04 on April 1st, 2023 UTC.PASS
Compiler IssuesN/APASS
Delegate Call to Untrusted ContractN/APASS
Dependence on Predictable VariablesN/APASS
Ether/Token TheftN/APASS
Flash LoansN/APASS
Front RunningN/APASS
Improper EventsN/APASS
Improper Authorization SchemeN/APASS
Integer Over/UnderflowN/APASS
Logical IssuesN/APASS
Oracle IssuesN/APASS
Outdated Compiler VersionN/APASS
Race ConditionsN/APASS
ReentrancyN/APASS
Signature IssuesN/APASS
Unbounded LoopsN/APASS
Unused CodeN/APASS
Overall Contract Safety PASS

Inheritance Chart

Smart Contract Audit - Inheritance

Function Graph

Smart Contract Audit - Graph

Functions Overview


 ($) = payable function
 # = non-constant function
 
 Int = Internal
 Ext = External
 Pub = Public

 +  Context 
    - [Int] _msgSender
    - [Int] _msgData

 + [Int] IERC20 
    - [Ext] totalSupply
    - [Ext] balanceOf
    - [Ext] transfer #
    - [Ext] allowance
    - [Ext] approve #
    - [Ext] transferFrom #

 + [Lib] SafeMath 
    - [Int] add
    - [Int] sub
    - [Int] sub
    - [Int] mul
    - [Int] div
    - [Int] div
    - [Int] mod
    - [Int] mod

 + [Lib] Address 
    - [Int] isContract
    - [Int] sendValue #
    - [Int] functionCall #
    - [Int] functionCall #
    - [Int] functionCallWithValue #
    - [Int] functionCallWithValue #
    - [Prv] _functionCallWithValue #

 +  Ownable (Context)
    - [Int]  #
    - [Pub] owner
    - [Pub] renounceOwnership #
       - modifiers: onlyOwner
    - [Pub] transferOwnership #
       - modifiers: onlyOwner
    - [Pub] geUnlockTime
    - [Pub] lock #
       - modifiers: onlyOwner
    - [Pub] unlock #

 + [Int] IUniswapV2Factory 
    - [Ext] feeTo
    - [Ext] feeToSetter
    - [Ext] getPair
    - [Ext] allPairs
    - [Ext] allPairsLength
    - [Ext] createPair #
    - [Ext] setFeeTo #
    - [Ext] setFeeToSetter #

 + [Int] IUniswapV2Pair 
    - [Ext] name
    - [Ext] symbol
    - [Ext] decimals
    - [Ext] totalSupply
    - [Ext] balanceOf
    - [Ext] allowance
    - [Ext] approve #
    - [Ext] transfer #
    - [Ext] transferFrom #
    - [Ext] DOMAIN_SEPARATOR
    - [Ext] PERMIT_TYPEHASH
    - [Ext] nonces
    - [Ext] permit #
    - [Ext] MINIMUM_LIQUIDITY
    - [Ext] factory
    - [Ext] token0
    - [Ext] token1
    - [Ext] getReserves
    - [Ext] price0CumulativeLast
    - [Ext] price1CumulativeLast
    - [Ext] kLast
    - [Ext] mint #
    - [Ext] burn #
    - [Ext] swap #
    - [Ext] skim #
    - [Ext] sync #
    - [Ext] initialize #

 + [Int] IUniswapV2Router01 
    - [Ext] factory
    - [Ext] WETH
    - [Ext] addLiquidity #
    - [Ext] addLiquidityETH ($)
    - [Ext] removeLiquidity #
    - [Ext] removeLiquidityETH #
    - [Ext] removeLiquidityWithPermit #
    - [Ext] removeLiquidityETHWithPermit #
    - [Ext] swapExactTokensForTokens #
    - [Ext] swapTokensForExactTokens #
    - [Ext] swapExactETHForTokens ($)
    - [Ext] swapTokensForExactETH #
    - [Ext] swapExactTokensForETH #
    - [Ext] swapETHForExactTokens ($)
    - [Ext] quote
    - [Ext] getAmountOut
    - [Ext] getAmountIn
    - [Ext] getAmountsOut
    - [Ext] getAmountsIn

 + [Int] IUniswapV2Router02 (IUniswapV2Router01)
    - [Ext] removeLiquidityETHSupportingFeeOnTransferTokens #
    - [Ext] removeLiquidityETHWithPermitSupportingFeeOnTransferTokens #
    - [Ext] swapExactTokensForTokensSupportingFeeOnTransferTokens #
    - [Ext] swapExactETHForTokensSupportingFeeOnTransferTokens ($)
    - [Ext] swapExactTokensForETHSupportingFeeOnTransferTokens #

 +  Pumptopia (Context, IERC20, Ownable)
    - [Pub]  #
    - [Pub] name
    - [Pub] symbol
    - [Pub] taxFee
    - [Pub] teamFee
    - [Pub] decimals
    - [Pub] totalSupply
    - [Pub] balanceOf
    - [Ext] setIsTxLimitExempt #
       - modifiers: onlyOwner
    - [Pub] setFree #
       - modifiers: onlyOwner
    - [Pub] unSetFree #
       - modifiers: onlyOwner
    - [Pub] transfer #
    - [Pub] allowance
    - [Pub] approve #
    - [Pub] setAutomatedMarketMakerPair #
       - modifiers: onlyOwner
    - [Prv] _setAutomatedMarketMakerPair #
    - [Pub] transferFrom #
    - [Pub] increaseAllowance #
    - [Pub] decreaseAllowance #
    - [Pub] isExcluded
    - [Ext] setExcludeFromFee #
       - modifiers: onlyOwner
    - [Pub] totalFees
    - [Pub] deliver #
    - [Pub] reflectionFromToken
    - [Pub] tokenFromReflection
    - [Pub] excludeAccount #
       - modifiers: onlyOwner
    - [Pub] includeAccount #
       - modifiers: onlyOwner
    - [Prv] removeAllFee #
    - [Prv] restoreAllFee #
    - [Pub] isExcludedFromFee
    - [Prv] _approve #
    - [Prv] _transfer #
    - [Prv] swapTokensForEth #
       - modifiers: lockTheSwap
    - [Prv] sendETHToTeam #
    - [Ext] manualSwap #
       - modifiers: onlyOwner
    - [Ext] manualSend #
       - modifiers: onlyOwner
    - [Ext] setSwapEnabled #
       - modifiers: onlyOwner
    - [Prv] _tokenTransfer #
    - [Prv] _transferStandard #
    - [Prv] _transferToExcluded #
    - [Prv] _transferFromExcluded #
    - [Prv] _transferBothExcluded #
    - [Prv] _takeTeam #
    - [Prv] _reflectFee #
    - [Ext]  ($)
    - [Prv] _getValues
    - [Prv] _getTValues
    - [Prv] _getRValues
    - [Prv] _getRate
    - [Prv] _getCurrentSupply
    - [Prv] _getTaxFee
    - [Prv] _getMaxTxAmount
    - [Pub] _getETHBalance
    - [Ext] changeRouterVersion #
       - modifiers: onlyOwner
    - [Ext] _setTaxFee #
       - modifiers: onlyOwner
    - [Ext] _setTeamFee #
       - modifiers: onlyOwner
    - [Ext] _setFees #
       - modifiers: onlyOwner
    - [Ext] _setTeamPercent #
       - modifiers: onlyOwner
    - [Ext] _setTreasuryWallet #
       - modifiers: onlyOwner
    - [Ext] _setMarketingWallet #
       - modifiers: onlyOwner
    - [Ext] _setNumOfTokensToExchangeForTeam #
       - modifiers: onlyOwner
    - [Ext] _setMaxTxAmount #
       - modifiers: onlyOwner
    - [Ext] _setMaxWalletToken #
       - modifiers: onlyOwner

About SourceHat

SourceHat has quickly grown to have one of the most experienced and well-equipped smart contract auditing teams in the industry. Our team has conducted 1800+ solidity smart contract audits covering all major project types and protocols, securing a total of over $50 billion U.S. dollars in on-chain value!
Our firm is well-reputed in the community and is trusted as a top smart contract auditing company for the review of solidity code, no matter how complex. Our team of experienced solidity smart contract auditors performs audits for tokens, NFTs, crowdsales, marketplaces, gambling games, financial protocols, and more!

Contact us today to get a free quote for a smart contract audit of your project!

What is a SourceHat Audit?

Typically, a smart contract audit is a comprehensive review process designed to discover logical errors, security vulnerabilities, and optimization opportunities within code. A SourceHat Audit takes this a step further by verifying economic logic to ensure the stability of smart contracts and highlighting privileged functionality to create a report that is easy to understand for developers and community members alike.

How Do I Interpret the Findings?

Each of our Findings will be labeled with a Severity level. We always recommend the team resolve High, Medium, and Low severity findings prior to deploying the code to the mainnet. Here is a breakdown on what each Severity level means for the project:

  • High severity indicates that the issue puts a large number of users' funds at risk and has a high probability of exploitation, or the smart contract contains serious logical issues which can prevent the code from operating as intended.
  • Medium severity issues are those which place at least some users' funds at risk and has a medium to high probability of exploitation.
  • Low severity issues have a relatively minor risk association; these issues have a low probability of occurring or may have a minimal impact.
  • Informational issues pose no immediate risk, but inform the project team of opportunities for gas optimizations and following smart contract security best practices.