Must Have skills as an auditor

Jun 26
10
min of reading

As an auditor, you must be able to Identifyall possible call paths for each function. Different entry functions can havevarious impacts based on their parameters and the context in which they arecalled.

After you have read the thread, check outthe function and spot the bug.

Consider a scenario where these functionshave an additional parameter, like from to deposit, withdraw, or harvest from apermissioned address, or to to withdraw to a different address or deposit intoa different address. This complexity introduces numerous potential call paths

When you audit a function, you mustconsider every possible way that function can be called. This means not justlooking at the function in isolation but understanding how it interacts withthe rest of the contract and potentially external contracts as well.

What to look for (1):

Security Vulnerabilities: Each call pathcan introduce potential security vulnerabilities, such as reentrancy attacks,access control issues, or unexpected interactions with other internal functionsor external contracts.

What to look for (2):

Functionality Bugs: A function might behaveas intended when called in one context but could fail or behave unexpectedly ina different context.

Methodology (1):

Map Out All Call Paths: Start byidentifying all possible call paths that lead to the function. This includesdirect calls from users, as well as calls from other functions within thecontract or from external contracts.

Methodology (2):

Analyze Each Path Individually: For eachpath, consider the permissions required, the state of the contract before thecall, and how the state changes after the call.

Methodology (3):

Consider External Interactions: If thefunction interacts with external contracts, consider the state and behavior ofthose contracts as well.

Methodology (4):

Look for Edge Cases: Pay special attentionto edge cases, such special boundaries, or calls that might result in numericalunderflows or overflows.

If you came until here, you should now beable to find the bug. Comment it and retweet if you found it (familiarity withSynthetix Staking Rewards is necessary).

Read the original article

Related articles