Knownsec Blockchain Lab|DINA Project: New Exploration of National Dividend Model

Knownsec Blockchain Lab
5 min readJun 16, 2021

--

The safemoon project, which is very popular some time ago, has set off a wave of speculation in the currency circle. Many imitation disks have emerged one after another. We have also analyzed its source code. You can refer to the previous article for details. Knownsec Blockchain Lab will show you its upgraded version—DINA (https://dina.finance/).

DINA’s original creation of a gradient fee burning based on the health of the liquid pool, combined with the DeFi+MeMe+FOMO gameplay, launched the liquidity pool at 13:14 on June 5th (UTC international standard time), the opening price is 0.000004$, the current price (June 16th) 0.000160045$, an increase of 4001%.

The mechanism of DINA is mainly divided into 9 sections:

1.Purchase limit
2.Floating rate
3.Static reward
4.Automatic LP
5.Prevent tax avoidance
6.Fomo prize pool
7.Manual destruction
8.Prevent smashing
9.Security Mechanism

Since DINA is an upgraded version of safemoon, here is only the code analysis of the new functional sections: floating rate, Fomo bonus pool, manual destruction and prevention of smashing.

Floating rate

Determine the handling fee rate according to the health status of the liquidity pool, and innovate a stable balance mechanism.

When the flow pool is ≤ 1 million USDT, the fee rate is 30%
When more than 1 million USDT ≤ 3 million USDT, the fee rate is 25%
When more than 3 million USDT ≤ 5 million USDT, the fee rate is 20%
When more than 5 million USDT and less than 10 million USDT, the fee rate is 15%
When the liquidity pool> 10 million USDT, the fee rate is 10%

DINA mediates and collects transaction fees (including destruction, dividends, and adding liquidity) based on the balance of USDT in the transaction pair. Looking at the code details, it is found that it initializes the handling fee values ​​of different stages, and then uses the getHealthLevel function to query the USDT balance in the trading pair to map the corresponding stages, as shown in Figure 1 and Figure 2:

1.Initialize the array of corresponding rates in different stages
2.Query liquidity level

Fomo prize pool

The function of the Fomo bonus pool enhances the playability of the DINA project. 1%-5% of any transfer will continue to be added to the Fomo bonus pool contract account. If no token is purchased within 4 hours, 50% of the Fomo bonus pool will be awarded to the last token purchaser.

The audit code found that the contract created a Fomo contract account. Since the account will receive a portion of the handling fee for each transaction, the Fomo contract will call the transferNotify and swap functions to record the last purchaser’s address and the payment. The received handling fee is converted into USDT. If the transaction time is greater than 4 hours when the transfer is called next time, a reward USDT will be sent to the recipient of the previous transaction. The code is shown in Figure 3 and Figure 4:

3.The DINA contract calls the Fomo bonus pool function
4.Fomo contract related functions

Manual destruction

In order to reduce the risk of hackers, make better use of the USDT in the bonus pool. When the trigger conditions are met, manually call the contract function to trigger 50% of the USDT for repurchase and destruction of tokens.

Check the code, this function is also in the Fomo contract, and the calling authority can only be the project address. The function first calls the swap function to convert the DINA tokens in the contract to USDT, and then converts half of the USDT under the contract to DINA tokens and enters the black hole contract, as shown in Figure 5:

The operation of manual destruction indirectly increases the value of DINA tokens and also improves the playability of the Fomo bonus pool. As of June 9, the Fomo prize pool has 278,658 USDT, as shown in Figure 6:

5.buyAndBurn function
6.Fomo bonus pool amount in the official website

Prevent smashing

Community operators should not hold tokens. Selling tokens in large quantities will go against the original intention of DINA's decentralized design. Therefore, there is no team allocation, and 2% of any transaction will be automatically transferred to the community operator.

This design is equivalent to an additional handling fee on the original basis. Unlike other handling fees (dividends, Fomo and liquidity), the handling fees charged by community operators will not change due to changes in the USDT balance of the trading pair. A fixed charge of 2% of the transaction amount is charged each time. The code is shown in Figure7.

7.Screenshots of the operator fee collection code

Looking at the DINA project itself, it is a continuation and expansion of the universal dividend gameplay. It makes up for the lack of playability and constant handling fees of the previous safemoon version, and adds new functions such as a new floating rate and Fomo mechanism. However, it is still inherited from the ERC20 token contract, which is an extension of the token gameplay. I hope everyone will pay attention to the changes in the environment when speculating in the currency circle. As for how long it will be popular, let us wait and see.

About Us: Knownsec Blockchain Lab has a team of top international blockchain security experts and 9 years of experience in security services for leading blockchain companies. It has served as the world’s leading digital currency exchange, wallet, underlying public chain, Smart contracts and other projects conduct security audits and defense deployments, and maintain the leading domestic core competitiveness in blockchain technology security, risk control security, and anti-hacking security.

Official Website | Designated storage platform | Contact us | Twitter

--

--