Part of Quantstamp’s retainer series
Quantstamp reviewed Nayms 2024 (Retainer) on 3 May 2024: 33 findings, 0 critical; 18 marked fixed, 11 acknowledged, 4 open.
Report hosted on certificate.quantstamp.com.
Trustblock does not review code.
Statuses are the security firm’s own, from its report.
| Severity | Open | Acknowledged | Fixed |
|---|---|---|---|
| Critical | 0 | 0 | 0 |
| High | 0 | 0 | 4 |
| Medium | 2 | 0 | 2 |
| Low | 2 | 11 | 12 |
If a rebase token is used as a dividend token, then the dividend bank would collect the interest of any unclaimed dividends. As a result, users would need to claim dividends if they want to gain interest on these tokens. The severity level is undetermined since it is unclear if rebase tokens will be used as dividend tokens.
Any address holding p-tokens can transfer them to any other object that represents an address, with a transfer using the contract `ERC20Wrapper`. This could have an unexpected impact if some addresses should only be expected to receive p-tokens after specific functions are executed and not via direct transfers.
While function `LibFeeRouter._removeFeeSchedule()` explicitly prevents the removal of default fee schedules (`LibConstants.DEFAULT_FEE_SCHEDULE`), no such check is performed in function `LibFeeRouter._addFeeSchedule()`, allowing system admins to indirectly reset or modify the default fee schedules.
In the contract `InitDiamond`, the function `init()` can be front-run by anyone once the contract is deployed.
It is possible to enable the staking feature on different entities with the same staking token by using a privileged role. If this happens, since boosts and balances mapping are stored at the level of the staking token and not at the level of the entity, staking users will be incentivized to stake for the entity with the most profitable boost mechanism (depending on the values of `a`, `r` and `divider`), while still being eligible to the rewards of both entities. Further, this could lead to other accounting issues like double accounting or staking reward tokens being blocked due to the restriction of having only one reward token per interval.
Similar to the existing dividend system, it is not guaranteed that stakers will receive any rewards when staking for a given entity, as those need to be manually payed into the protocol by an address with the role of entity admin in the context of the entity staked for.
In the function `_onboardUser()`, the fact that we assign the onboarded user to a role in both the entity's context and the system's context should be confirmed to be expected or not.
In `LibSimplePolicy.payClaim()`, an entity may need to pay a claim for a given policy even after the policy is matured and underlying funds are released, which can be problematic as there won't be enough funds in the entity. Per communication with the team, we understand that when a policy matures, funds get unlocked. However, there might be cases of retroactive payment of claims i.e. an incident happened while the policy was active, but it was reported only after it matured. Those still need to be paid out, but the contracts no longer lock the funds. The system currently cannot guarantee the funds to be available indefinitely, so best effort and communication with the insured party are used to settle such cases. **Note:** this issue is close to the issue #23 of the previous audit (link [here](https://certificate.quantstamp.com/full/nayms-2/79da5daf-4326-4f12-a71c-828b72fbea09/index.html)).
Once the self-onboarding of a user has been approved by an onboarding approver, a race condition exists between the conflicting functions: * `onboard()` to be called by the user to self onboard; * `cancelSelfOnboarding()` to be called by a system manager;
According to the current codebase, an infinite amount of NAYM tokens can be minted, since: * the contract is a diamond pattern and the storage can be updated following governance decisions and the `PhasedDiamondCutFacet` process; * a `Minter` role is defined and can mint any amount of NAYM; * if the `Minter` role is revoked (set to `address(0)`), `sysAdmins` can reassign a `Minter` even if it has been previously revoked. Details regarding the expected total supply of the token were not found in the documentation.
In the previous implementation, trades on the market were restricted such that either one of the sell/buy tokens must be an external token, whereas the other one is an internal (participation) token. However, in the updated code, internal trading between external tokens is now allowed to let people trade internally NAYM tokens. If appropriate, the team may want to restrict the trading of external tokens to be between the NAYM Token and supported external tokens, as opposed to allowing unrestricted trading of external tokens.
The report names a repository or files. Open the report to see its scope.
Repository and files the report names (245)
236 projects reviewed · 332 reports · latest Oct 2026
See Quantstamp’s auditsSomething 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