TourismX (TRMX ) - Audit

CertiK3 addresses on BNB Chain

CertiK reviewed TourismX (TourismX (TRMX ) - Audit) on 12 Oct 2022: 8 findings, 0 critical; none marked fixed.

No open critical findings
Open the reportOpen TourismX’s security record

Report hosted on skynet.certik.com.

Trustblock does not review code.

Findings8

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

SeverityOpenAcknowledgedFixed
Critical000
High200
Medium000
Low600
HighCentralization Risks in TokenVesting.solOpen

Several contracts throughout the project, implement and rely on privileged roles to modify configuration variables. Having this role and functionality allows the project to implement dynamic adjustments to the protocol that can be beneficial to both the deployer and users. However, it also introduces a single point of failure that can compromise the whole protocol. In the `TokenVesting` contract, the role `_owner` has authority over the following functions: - `TokenVesting.setSellContract`: Changes the contract that interacts with the contract `TokenVesting` - `TokenVesting.createVestingSchedule`: Create vesting schedules - `TokenVesting.revoke`: Revoke vesting schedules - `TokenVesting.withdraw`: Withdraw `_token` up to the amount not vested In the `TokenVesting` contract, the address `sellContract` has authority over the following function: - `TokenVesting.createVestingSchedule`: Create vesting schedules In the `TourismXToken` contract, the role `_owner` has authority over the following functions: - `TourismXToken.pause`: Pause token transfer - `TourismXToken.unpause`" Unpause token transfer In the `Sell` contract, the role `_owner` has authority over the following functions: - `Sell.setVestingContract`: Change the `vestingContract` to be called - `Sell.setPayToken`: Change the `payToken` used to start vesting - `Sell.setDuration`: Change the duration period to vesting reward - `Sell.setTokenPrice`: Change the price of the vesting token - `Sell.setSlicePeriodSeconds`: Change the time required to unlock a portion of the vesting reward - `Sell.setCliff`: Change the minimum time required to earn the vesting reward - `Sell.setRevocable`: Change whether a vesting schedule can be revoked or not

HighInitial Token DistributionOpen

Despite the comment on line 787 stating all tokens are minted and "transferred to the multi-sig owner wallet", all the tokens were initially minted to eight addresses and the [owner](https://bscscan.com/address/0xc2c6cefb6656ab6225dbef06ce1d9472643d2b96) of the contract is not a multi-sig wallet. Having the tokens minted to a few selected addresses poses a centralization risk and allows the addresses to drastically manipulate the supply and potentially price of the token. Furthermore, any compromise to these addresses can heavily impact the project.

LowFunction Should Be Declared ExternalOpen

Functions with external visibility are gas efficient compared to functions with public visibility. The following functions are declared `public` despite not being called internally and therefore can be declared `external` instead. In the contract `TokenVesting`: - `TokenVesting.setSellContract` - `TokenVesting.createVestingSchedule` - `TokenVesting.revoke` - `TokenVesting.withdraw` - `TokenVesting.getVestingSchedules` - `TokenVesting.getVestingSchedulesByOwner` - `TokenVesting.getAllVestingSchedules` - `TokenVesting.getLastVestingScheduleForHolder` In the contract `Sell`: - `Sell.setVestingContract` - `Sell.setPayToken` - `Sell.setDuration` - `Sell.setTokenPrice` - `Sell.setSlicePeriodSeconds` - `Sell.setCliff` - `Sell.setRevocable` - `Sell.buy`

LowLack of input validationOpen

Several inputs are lacking input validation such as checking if an address is not zero or the start time is greater than the current block time. Other checks that may benefit include checking duration is greater than cliff. Such checks minimize unintended mistakes such as typos and help to keep the smart contract from functioning properly and as intended.

LowMissing eventsOpen

Events are missing throughout the project and should be emitted whenever state variables are modified and/or core functions are called. Having events benefit those monitoring the protocol to easily filter relevant events. The following functions can benefit from emitting events: In the contract `TokenVesting`: - `TokenVesting.setSellContract` - `TokenVesting.createVestingSchedule` - `TokenVesting.revoke` - `TokenVesting.withdraw` - `TokenVesting.release` In the contract `Sell`: - `Sell.constructor` - `Sell.setVestingContract` - `Sell.setPayToken` - `Sell.setDuration` - `Sell.setTokenPrice` - `Sell.setSlicePeriodSeconds` - `Sell.setCliff` - `Sell.setRevocable` - `Sell.buy`

LowUnnecessary BNB related implementationOpen

Despite the contract not requiring or using BNB, `fallback` and `receive` functions are implemented and addresses are casted to payable addresses. If a user unintentionally sends the BNB, there is currently no way of withdrawing this BNB and will be stuck in the contract.

LowUnnecessary use of SafeMathOpen

As of Solidity version 0.8, arithmetic operations that result in overflow and underflow will automatically be reverted. Therefore the use of SafeMath is unnecessary and regular arithmetic operators such as `+`, `-`, `*`, and `/` can be used without integers underflowing or overflowing.

LowUnused return valueOpen

The current implementation does not revert the transaction when the transfer fails by returning a `false` value. If `payToken` is ever changed in the future, this can unexpectedly lead to the creation of vesting schedules despite the `payToken` not having properly transferred.

Contracts in scope3

AddressChainSource code
0x882e295c4b851df7a347679dab8c2489e9e58c96Chain: BNB ChainSource code: Verified source
0x747470777fe622033271d465ce14ad7e316bca58Chain: BNB ChainSource code: Verified source
0xa6472bc7c0e2266034bb40edd8c6e8961cf45826Chain: BNB ChainSource code: Verified source

Part of TourismX’s security record

TourismX
Audits1 audit by 1 firmLast audit Oct 2022, by CertiK.
Critical findingsNo open critical findingsIn 1 report.
Open TourismX’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