ARK

CertiKFiles named in the report

CertiK reviewed Ark Finance (ARK) on 3 Jan 2023: 25 findings, 3 critical; 19 marked fixed, 6 open.

3 critical findings, fixed
Open the reportOpen Ark Finance’s security record

Report hosted on skynet.certik.com.

Trustblock does not review code.

Findings25

Statuses are the security firm’s own, from its report.

SeverityOpenAcknowledgedFixed
Critical003
High200
Medium001
Low4015
HighCentralization RisksOpen

In the contract `ARK_SWAP` the role `CEO` has authority over the functions shown in the diagram below. Any compromise to the `CEO` account may allow the hacker to take advantage of this authority and 1) Change the following tax percentages by calling the `setSellTaxes()` function: - `busdSellTax` - `busdSellDumpTax` - `liquiditySellTax` - `vaultSellTax` - `liquiditySellDumpTax` - `vaultSellDumpTax` - `totalSellTax` - `totalSellDumpTax` 2) Change the value of `bondTax` using the `setBondTax()` function. 3) Change the value of `maxSellPerDay` using the `setMaxSellPerDay()` function. 4) Change the following tax percentages by calling the `setBuyTaxes()` function: - `busdTax` - `liquidityTax` - `totalBuyTax` 5) Add or remove a user from `isArk` mapping which has its own centralization risks (see below). ![](https://accelerator-tasks-prod.acc.corp.certik.com/cd9fb222d82e477b8f229d9fb1e54b5d/diagrams/centralization_ARK_SWAP-ARK_SWAP-CEO.svg) --- In the contract `ARK_SWAP` the role `isArk` has authority over the functions shown in the diagram below. Any compromise to the `isArk` account may allow the hacker to take advantage of this authority and 1) Change the value of `priceCeiling` or `priceFloor` using the `setCeiling()` and `setFloor()` functions. 2) Change the value of `priceCeiling` and `priceFloor` using the `setTarget()` function. 3) Change the value of following variables using the `setAutoPriceSettings()` - `targetPriceIncrease` - `targetPriceDecrease` - `targetPriceChangeDivisor` 4) Change the value of `autoTargetPrice` using the `toggleAutomaticTargetPrice()` function. ![](https://accelerator-tasks-prod.acc.corp.certik.com/cd9fb222d82e477b8f229d9fb1e54b5d/diagrams/centralization_ARK_SWAP-ARK_SWAP-isArk.svg) --- In the contract `ARK_TOKEN` the role `CEO` has authority over the functions shown in the diagram below. Any compromise to the `CEO` account may allow the hacker to take advantage of this authority and 1) Change the `vaultTax` and `liqTax` using the `setTax()` function. 2) Change the `vault` address, which receives the `vaultTax` percentage of tax on transactions that are taxed, using the `setVault()` function. 3) Change the `treasury` address, which can receive the stuck tokens in the contract, using the `setNewTreasury()` function. 4) Change the `swap` address using the `setNewArkSwapAddress` function. 5) Add or remove users from the vault using the `addVault()` and `removeVault()` functions. 6) Send all the stuck tokens in the contract to the `treasury` address, using the `sendTokenToTreasury()` function. 7) Make an address `limitless` or limit it using the `makeAddressLimitless()` and `makeAddressLimited()` functions. A `limitless` address is allowed to transfer the tokens directly to the `pair` and could alter the price of the `ARK` token without having to worry about the change, in the price of the token, in the allowed range set by `keepPrice()` function. 8) Add or remove a wallet from the `taxFreeWallet[]` mapping using the `setTaxStatusOfWallet()` function. 9) Change the value of `swapActive` bool using the `toggleSwap()` function. 10) Transfer the stuck `BNB` to the `treasury` address, using the `rescueBnb()` function. 11) In addition, a malicious user can add a malicious address to the `isVault` mapping or change the `swap` address to a malicious address. They can then initiate a transfer using the malicious address to a `recipient` address with an amount larger than their current balance. The difference in tokens is minted to themselves and transferred to the `recipient`. This allows a malicious user to mint an unlimited supply to addresses they choose. ![](https://accelerator-tasks-prod.acc.corp.certik.com/cd9fb222d82e477b8f229d9fb1e54b5d/diagrams/centralization_ARK_TOKEN-ARK_TOKEN-CEO.svg)

HighInitial Token DistributionOpen

All `ARK` tokens are sent to the `CEO` when deploying the contract. This is a potential centralization risk as the `CEO` can distribute `ARK` tokens without the consensus of the community.

Low`vault` is not initializedOpen

The `vault` state variable is not initialized, thus if a user transfers tokens, `takeTax()` is executed and it will send tax tokens to the zero address. Those tokens will be lost forever.

LowFunctions Supporting Fee on Transfer TokensOpen

The function `buyBUSDWithETH()` uses `swapExactETHForTokensSupportingFeeOnTransferTokens()`, when neither token being swapped between has a fee on transfer. The functions `buyArk()` and `sellArk()` both use `swapExactTokensForTokens()`, however if `swapActive` is false and a user calls one of these functions, then there will be a fee on transfer of the token.

LowMissing checksOpen

In ARK_SWAP.sol the following checks are missing: - In `setSellTaxes()` is not checked that `totalSellTax + totalSellDumpTax` is less than or equal to 100. Otherwise function like `expectedBUSDFromARKWithDumpTax()` or `takeSellTax()` will revert due to underflow. - In `setBuyTaxes()` is not checked that `totalBuyTax` is less than or equal to 100. Otherwise functions like `expectedARKFromBUSD()` will revert due to underflow. - In `setBuyTaxes()` is not checked that `busdTax + liquidityTax` is less than or equal to 100. Otherwise `takeBuyTax()` will calculate a wrong taxed amount. - In `setAutoPriceSettings()` is not checked that the input `down` assigned to `targetPriceDecrease` is less than or equal to the new input `divisor` assigned to `targetPriceChangeDivisor`. Otherwise `autoDecreaseTarget()` will revert due to underflow. - In `setAutoPriceSettings()` is not checked that the input `divisor` assigned to `targetPriceChangeDivisor` is not zero. Otherwise `autoDecreaseTarget()` and `autoIncreaseTarget()` will revert due to division by zero. - In `setBondTax()` is not checked that the input `percent` is less than or equal to 100. Otherwise functions like `addLiquidityWithArk()` will revert due to underflow. - In `addLiquidityWithArk()` is not checked if the input `amount` is greater than zero. - In `removeLiquidity()` is not checked if the input `amount` is greater than zero. - In `buyArkWithETH()` is not checked if `msg.value` is greater than zero. - In `setCeiling()` is not checked if the input `ceiling` is greater than the current `priceFloor`. - In `setFloor()` is not checked if the input `floor` is lower than the current `priceCeiling`. - In `setBondTax()`, it is not checked if the input `percent` is greater than the sum of `instantPercent` and `poolPercent`. Otherwise `distributeTax()` will revert due to underflow. - In `toggleAutomaticTargetPrice()` it should be checked if `autoTargetPrice` value is already equal to `active`. - In `setArkWallet()` it should be checked if `arkWallet` has a value equal to `status` stored in `isArk` mapping. --- In ARK_TOKEN.sol the following checks are missing: - In the `constructor()` is not checked if the `pair` returned from `createPair()` is the zero address. - In `sendTokenToTreasury()` is not checked if `tokenToRescue` is the zero address. - In `toggleSwap()` is not checked if `swapActive` has already a status equal to the input `active`. - In the function `addVault()`, it is not checked if the address `vaultAddress` is already in the vault before adding it. - In the function `removeVault()`, it is not checked if the address 'vaultAddress` is even in the vault before removing it. - In the function `makeAddressLimitless()`, it is not checked if the address `addressThatShouldBeLimitless` is already `limitless`. - In the function `makeAddressLimited()`, it is not checked if the address `addressThatShouldBeLimited` is even `limitless` before limiting it.

LowOut of Scope DependenciesOpen

The contract `ARK_SWAP` serves as the underlying entity to interact with VAULT, BOND and LEGACY contracts that are not in this audit's scope. The audit treats contracts that are out of scope as black boxes and assumes their functional correctness. However, in the real world, those contracts can be compromised.

Contracts in scope

No deployed address is recorded for this audit.

The report names a repository or files. Open the report to see its scope.

Repository and files the report names (2)

  • ARK_TOKEN.sol
  • ARK_SWAP.sol

Part of Ark Finance’s security record

Ark Finance
Audits1 audit by 1 firmLast audit Jan 2023, by CertiK.
Critical findingsNo open critical findingsIn that report, 3 critical findings were reported. Each is marked fixed by the firm that reported it.
Open Ark Finance’s security record

Security firm

CertiK

1,045 projects reviewed · 1,376 reports · latest May 2025

See CertiK’s audits

Something 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