*Paid Advertisement. Not financial advice. RugDoc is not responsible for the projects showcased here. DYOR and ape safu.

How to verify if a Farm uses an Anti-Whale Function (Avax)

How to verify if a Farm uses an Anti-Whale Function (Avax)

Anti-whale functions are an important extra security layer to a farm. They limit big players (whales ór malicious developers) to dump or pump huge amounts of their token by setting a maximum sell/buy limit. In this guide we will show you how to check whether or not a farm, on the Avalanche network, has an anti-whale function in place.

Step 1. Find the MasterChef contract address #

The first thing we need to do is to find the MasterChef contract address. You can do so by going through our reviewed farms list or by looking on the website of the farm. Usually, the doc page should have some info about the MasterChef contract. If you’re still confused on how to get the MasterChef contract address, check out this guide.

Step 2. Open the MasterChef contract #

Open the Avalanche block explorer and paste the MasterChef contract address in the search bar and hit enter. In this guide we’ll use Onyx Farm’s MasterChef.

Contract address masterchef avax block explorer

Step 3. Search for the anti-whale function #

Once you have opened the MasterChef contract, look for the ‘Code’ tab and select it.

Code tab avalanche block explorer

Look for a section that contains the name of the farm’s governance token. In this case, the section is called ‘OnyxToken.sol’. Click inside the code box and press Ctrl+f. Use one of the following keywords to find the anti-whale function: ‘Whale’, ‘Anti’ or ‘maxtransferamount’.

anti-whale function in coding

You can conclude from the following lines that in Onyx Farm’s case, there’s a 1% anti-whale function present with a minimum of 0.5%:

// Max transfer amount rate in basis points. (default is 1% of total supply)
uint16 public maxTransferAmountRate = 100;
// Min value of the max transfer amount rate. (0.5%)
uint16 public constant maxTransferAmountRateMinValue = 50;

Good job! You have succesfully verified whether or not there’s an anti-whale function present for the farm of your interest! Make sure to read our other articles on our wiki too.

Updated on September 20, 2021
How do you feel about this article?

*Paid Advertisement. Not financial advice. RugDoc is not responsible for the projects showcased here. DYOR and ape safu.

Our mission here at RugDoc is to screen for hard rug code that results in 100% theft of ALL underlying funds for ALL participants.

This is the ONE part of the due diligence process that most people cannot simply do on their own as it costs thousands of dollars to hire a senior solidity developer to look over a farm for safety.

A project coin with terrible code can go up in price, and a project with good code and a good team can also go down in price.

Do NOT use our ratings to refer to your likelihood in making money if you invest in the project. They are ONLY in reference to code safety.

Everything else beyond code safety is YOUR responsibility to go do research on. We just make sure the casino you’re betting in won’t rob you before you even get to place a bet.

Our reviews for projects are organized into a few colors.

🟢 Least Risk
These projects are the least likely to hard or soft rug. Usually reserved for cornerstone projects of an ecosystem where it makes no financial sense for them to rug in any manner as they make more money just being legit.

🔵 Low Risk
These projects are usually established projects in an ecosystem that have a track record of success or have KYC’d to us or other authoritative sources in the real world. As a result, it is extremely unlikely for them to soft rug or hard rug their projects. The projects can still fail and the token price can go down, but usually more as a result of natural market forces.

⚪️ Some Risk
This is the default rating for projects with unknown teams but have code that is unlikely to have hard rug risk. Since the team is unknown and doesn’t have a track record of success, it’s entirely possible that they may try to soft rug by dumping tokens, abandoning the project, etc. Even a last minute contract swap to a malicious contract is possible. The only thing that is unlikely is a complete hard rug as long as you are 100% sure you deposit into the contract we review.

🟠 Medium Risk
Similar to Some Risk, but the underlying code itself is custom enough or complex enough that it warrants an elevated risk rating that needs deeper research. Make sure you read every point presented to make sure you’re comfortable with that before entering. Still unlikely to hard rug, but more chances of custom code behaving incorrectly and causing other issues.

🔴 High Risk
Project contains code or practices that are HIGHLY LIKELY to lead to catastrophic losses as they are right now. Make sure you read the description carefully as we will always warn what these issues are. If you see the words Hard Rug anywhere in the review, STAY FAR AWAY!

⚫️ Not Eligible
We reserve the right to not review exceedingly complex projects that would require tens of thousands of dollars of senior security analyst man hours. Typically these are projects that deal with leverage, lending, options, derivatives, and anything that is overly complex and which requires tons of peer reviews and audits from top audit companies.

Search

🟢 For owners who have made impactful changes and would like an update to their farm review:

1️⃣ Use #update at @RugDocChat with your description and proof of changes and it will be forwarded to our scanners.

2️⃣ This does not guarantee a change in your review.

3️⃣ Owners who have difficulty solving the issues can consider our Consultation Package - please contact @BaymaxCrypto on Telegram to discuss.