1/3 - Vigilance is key in identifying slippage protection oversights in DeFi contracts.
Lack of such mechanisms can expose users to price manipulation and potential losses.
2/3 - Regularly review transaction functions, especially in market and exchange contracts, to ensure they include slippage checks.
This practice not only safeguards the contract's integrity but also enhances user trust in the platform's resilience against market volatility.
1/3 - When reviewing smart contracts, one critical area to scrutinize is the correct implementation of interest accrual calculations.
A common pitfall is the misalignment of scaling factors, leading to significant discrepancies in interest distribution.
2/3 -Ensure that the scaling of variables like exchange rates aligns with the contract's intended logic, especially in financial applications.
This oversight, often subtle, can have profound implications on the contract's functionality and user trust.
⏰Solidity Reminder⏰
External calls can fail accidentally or deliberately, which can cause a DoS condition in the contract.
swcregistry.io/docs/SWC-113
⏰Solidity Reminder⏰
There exists a special variant of a message call, named delegatecall which is identical to a message call apart from the fact that the code at the target address is executed in the context of the calling contract
swcregistry.io/docs/SWC-112
⏰Solidity Reminder⏰
Several functions and operators in Solidity are deprecated. Using them leads to reduced code quality.
swcregistry.io/docs/SWC-111
⏰Solidity Reminder⏰
The Solidity assert() function is meant to assert invariants. Properly functioning code should never reach a failing assert statement.
swcregistry.io/docs/SWC-110
⏰Solidity Reminder⏰
Labeling the visibility explicitly makes it easier to catch incorrect assumptions about who can access the variable.
swcregistry.io/docs/SWC-108
⏰Solidity Reminder⏰
In the reentrancy attack (a.k.a. recursive call attack), a malicious contract calls back into the calling contract before the first invocation of the function is finished.
swcregistry.io/docs/SWC-107
⏰Solidity Reminder⏰
Due to missing or insufficient access controls, malicious parties can self-destruct the contract.
swcregistry.io/docs/SWC-106
⏰Solidity Reminder⏰
Due to missing or insufficient access controls, malicious parties can withdraw some or all Ether from the contract account.
swcregistry.io/docs/SWC-105
⏰Solidity Reminder⏰
The return value of a message call is not checked. Execution will resume even if the called contract throws an exception.
swcregistry.io/docs/SWC-104
⏰Solidity Reminder⏰
Contracts should be deployed with the same compiler version and flags that they have been tested with thoroughly.
swcregistry.io/docs/SWC-103
⏰Solidity Reminder⏰
Using an outdated compiler version can be problematic especially if there are publicly disclosed bugs and issues that affect the current compiler version.
swcregistry.io/docs/SWC-102
⏰Solidity Reminder⏰
An overflow/underflow happens when an arithmetic operation reaches the maximum or minimum size of a type.
swcregistry.io/docs/SWC-101
⏰Solidity Reminder⏰
Functions that do not have a function visibility type specified are public by default.
swcregistry.io/docs/SWC-100
Solau - 📨 DM for Audit retweeted
Super productive Saturday for me:
~ 3 hours learning more about DeFi and cryptoeconomics
~ 3 hours in-depth learning of the EVM
~ 3 hours reading past reports on @code4rena
Enjoying the grind 💪🫡

