skills/checklists/cyfrin-defi-integrations/SKILL.md
Cyfrin DeFi checklist covering integrations, token standards, and ecosystem-specific risks
npx skillsauth add apegurus/solidity-argus cyfrin-defi-integrationsInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
[ ] [SOL-Integrations-AC-1] Does the protocol use cETH token?
underlying() function in the cETH token contract can cause integration issues.[ ] [SOL-Integrations-AC-2] What happens if the utilization rate is too high, and collateral cannot be retrieved?
[ ] [SOL-Integrations-AC-3] What happens if the protocol is paused?
[ ] [SOL-Integrations-AC-4] What happens if the pool becomes deprecated?
[ ] [SOL-Integrations-AC-5] What happens if assets you lend/borrow are within the same eMode category?
[ ] [SOL-Integrations-AC-6] Do flash loans on Aave inflate the pool index?
[ ] [SOL-Integrations-AC-7] Does the protocol properly implement AAVE/COMP reward claims?
[ ] [SOL-Integrations-AC-8] On AAVE, what happens if a user reaches the maximum debt on an isolated asset?
[ ] [SOL-Integrations-AC-9] Does borrowing an AAVE siloed asset restrict borrowing other assets?
getSiloedBorrowing(address asset) to prevent unexpected problems.[ ] [SOL-Integrations-Balancer-1] Does the protocol use the Balancer's flashloan?
receiveFlashLoan function.[ ] [SOL-Integrations-Balancer-2] Does the protocol use Balancer's Oracle? (getTimeWeightedAverage)
[ ] [SOL-Integrations-Balancer-3] Does the protocol use Balancer's Boosted Pool?
[ ] [SOL-Integrations-Balancer-4] Does the protocol use Balancer vault pool liquidity status for any pricing?
[ ] [SOL-Integrations-Chainlink-CCIP-1] Does the receiver contract's _ccipReceive function properly validate the sourceChainSelector and sender address against an allowlist?
_ccipReceive to verify the any2EvmMessage.sourceChainSelector and decoded any2EvmMessage.sender against administratively controlled allowlists.[ ] [SOL-Integrations-Chainlink-CCIP-2] Does the sender contract validate the destinationChainSelector against an allowlist before calling ccipSend?
destinationChainSelector corresponds to an explicitly allowlisted chain.[ ] [SOL-Integrations-Chainlink-CCIP-3] Does the receiver contract properly decode data (any2EvmMessage.data) ?
[ ] [SOL-Integrations-Chainlink-CCIP-4] Does the application logic account for the potential latency introduced by waiting for source chain finality as defined by CCIP?
[ ] [SOL-Integrations-Chainlink-CCIP-5] Are the correct types of token pools (e.g., BurnMintTokenPool, LockReleaseTokenPool) deployed on the source and destination chains consistent with the desired token handling mechanism?
[ ] [SOL-Integrations-Chainlink-CCIP-6] Is proper router address verification implemented in the ccipReceive method?
[ ] [SOL-Integrations-Chainlink-CCIP-7] Are extraArgs parameters hardcoded instead of mutable in cross-chain message configurations?
[ ] [SOL-Integrations-Chainlink-CCIP-8] Is there a proper failure handling mechanism for CCIP messages to prevent blocking after Smart Execution window expiration?
[ ] [SOL-Integrations-Chainlink-VRF-1] Are all parameters properly verified when Chainlink VRF is called?
fullfillRandomWord function will not revert but return an incorrect value.fullfillRandomWord.[ ] [SOL-Integrations-Chainlink-VRF-2] Is it guaranteed that the operator holds sufficient LINK in the subscription?
[ ] [SOL-Integrations-Chainlink-VRF-3] Is a sufficiently high request confirmation number chosen considering chain re-orgs?
[ ] [SOL-Integrations-Chainlink-VRF-4] Are measures in place to prevent VRF calls from being frontrun?
[ ] [SOL-Integrations-GS-1] Do your modules execute the Guard's hooks?
checkTransaction(), checkAfterExecution()) can bypass critical security checks implemented in those hooks.[ ] [SOL-Integrations-GS-2] Does the execTransactionFromModule() function increment the nonce?
execTransactionFromModule(), it can cause issues when relying on it for signatures.execTransactionFromModule().[ ] [SOL-Integrations-LayerZero-1] Does the _debitFrom function in ONFT properly validate token ownership and transfer permissions?
_debitFrom function verifies whether the specified owner is the actual owner of the tokenId and if the sender has the correct permissions to transfer the token._debitFrom function to maintain token security.[ ] [SOL-Integrations-LayerZero-2] Which type of mechanism are utilized? Blocking or non-blocking?
[ ] [SOL-Integrations-LayerZero-3] Is gas estimated accurately for cross-chain messages?
[ ] [SOL-Integrations-LayerZero-4] Is the _lzSend function correctly utilized when inheriting LzApp?
lzEndpoint.send can introduce vulnerabilities. Using _lzSend is the recommended approach._lzSend function is used instead of making direct calls to lzEndpoint.send.[ ] [SOL-Integrations-LayerZero-5] Is the ILayerZeroUserApplicationConfig interface correctly implemented?
forceResumeReceive function to handle unexpected scenarios and unblock the message queue when needed.ILayerZeroUserApplicationConfig interface and ensure that the forceResumeReceive function is present and functional.[ ] [SOL-Integrations-LayerZero-6] Are default contracts used?
[ ] [SOL-Integrations-LayerZero-7] Is the correct number of confirmations chosen for the chain?
[ ] [SOL-Integrations-LSD-cbETH-1] How is the control over the cbETH/ETH rate determined? Are there specific addresses with this capability due to the onlyOracle modifier?
cbETH and ETH being controllable by a few addresses can introduce centralization risks and potential manipulations.onlyOracle permissions should be scrutinized and their actions should be transparent to the community.[ ] [SOL-Integrations-LSD-cbETH-2] How does the system handle potential decreases in the cbETH/ETH rate?
cbETH to ETH can decrease, which can impact users who hold or interact with cbETH.cbETH/ETH rate. Consider providing alerts or notifications for significant rate changes. Ensure there's a mechanism to handle or rectify situations where the rate decreases dramatically.[ ] [SOL-Integrations-LSD-rETH-1] Does the application account for potential penalties or slashes?
rETH.rETH.[ ] [SOL-Integrations-LSD-rETH-2] How does the system manage rewards accrued from staking?
rETH.rETH management.[ ] [SOL-Integrations-LSD-rETH-3] Does the application handle potential reverts in the burn() function when there's insufficient ether in the RocketDepositPool?
RocketDepositPool contract, the burn() function can fail. It's important for the system to handle these failures gracefully.burn() when there's insufficient ether or handle the revert gracefully, informing the user appropriately.[ ] [SOL-Integrations-LSD-rETH-4] What measures are in place to counteract potential consensus attacks on RPL nodes?
[ ] [SOL-Integrations-LSD-rETH-5] How does the system handle the conversion between ETH and rETH?
ETH and rETH might change over time based on the rewards accrued from staking. Ensure this dynamic is properly captured.ETH and rETH.[ ] [SOL-Integrations-LSD-sfrxETH-1] How does the system handle potential detachment of sfrxETH from frxETH during reward transfers?
sfrxETH detaches from frxETH during reward transfers, it could cause discrepancies in expected and actual values, especially if these transfers are controlled by a centralized entity like the Frax team's multi-sig contract.sfrxETH and frxETH.[ ] [SOL-Integrations-LSD-sfrxETH-2] Is the stability of the sfrxETH/ETH rate guaranteed or can it decrease in the future?
sfrxETH/ETH rate might be stable now, changes in the future could impact users and stakeholders, especially if they're not forewarned.sfrxETH/ETH rate. Ensure users are informed well in advance about any planned changes that could affect the rate.[ ] [SOL-Integrations-LSD-stETH-1] Is the application aware that stETH is a rebasing token?
stETH rebases, which can introduce complexities when integrated with DeFi platforms. Using wstETH can simplify integrations as it is non-rebasing.wstETH for simpler DeFi integrations and to avoid complexities associated with rebasing tokens.[ ] [SOL-Integrations-LSD-stETH-2] Are you aware of the overhead when withdrawing stETH/wstETH?
stETH or wstETH can introduce overheads, due to various problems like queue time, receipt of an NFT, and withdrawal amount limits.[ ] [SOL-Integrations-LSD-stETH-3] Does the application handle conversions between stETH and wstETH correctly?
stETH and wstETH can be tricky due to the rebasing nature of stETH. It's crucial to handle these conversions correctly to avoid potential issues.stETH are properly managed when converting between stETH and wstETH.[ ] [SOL-Integrations-Uniswap-1] Is the slippage calculated on-chain?
[ ] [SOL-Integrations-Uniswap-2] Are there refunds after swaps?
[ ] [SOL-Integrations-Uniswap-3] Is the order of token0 and token1 consistent across chains?
token0 and token1 in AMM pools may vary depending on the chain, which can lead to inconsistencies.[ ] [SOL-Integrations-Uniswap-4] Are the pools that are being interacted with whitelisted?
[ ] [SOL-Integrations-Uniswap-5] Is there a reliance on pool reserves?
[ ] [SOL-Integrations-Uniswap-6] Is pool.swap() directly used?
pool.swap() can bypass certain security mechanisms.[ ] [SOL-Integrations-Uniswap-7] Is unchecked used properly with Uniswap's math libraries?
unchecked due to solidity version specifics.unchecked in contracts utilizing Uniswap's math libraries to ensure safety and correctness.[ ] [SOL-Integrations-Uniswap-8] Is the slippage parameter enforced at the last step before transferring funds to users?
[ ] [SOL-Integrations-Uniswap-9] Is pool.slot0 being used to calculate sensitive information like current price and exchange rates?
pool.slot0 can be easily manipulated via flash loans to sandwich attack users.[ ] [SOL-Integrations-Uniswap-10] Is a hard-coded fee tier parameter being used?
[ ] [SOL-Token-FE-1] Are safe transfer functions used throughout the contract?
[ ] [SOL-Token-FE-2] Is there potential for a race condition for approvals?
[ ] [SOL-Token-FE-3] Could a difference in decimals between ERC20 tokens cause issues?
[ ] [SOL-Token-FE-4] Does the token implement any form of address whitelisting, blacklisting, or checks?
[ ] [SOL-Token-FE-5] Could the use of multiple addresses for a single token lead to complications?
[ ] [SOL-Token-FE-6] Does the token charge fee on transfer?
[ ] [SOL-Token-FE-7] Can the token be ERC777?
[ ] [SOL-Token-FE-8] Does the protocol use Solmate's ERC20.safeTransferLib?
ERC20.safeTransferLib do not check the contract existence and this opens up a possibility for a honeypot attack.[ ] [SOL-Token-FE-9] Is there a flash-mint functionality?
[ ] [SOL-Token-FE-10] What happens on zero amount transfer?
[ ] [SOL-Token-FE-11] Is the token an ERC2612 implementation?
DOMAIN_SEPARATOR() can lead to vulnerabilities in the ERC2612 permit functionality.DOMAIN_SEPARATOR() function.[ ] [SOL-Token-FE-12] Can the token be sent to any address?
[ ] [SOL-Token-FE-13] Is there a direct approval to a non-zero value?
[ ] [SOL-Token-FE-14] Is there a max approval used?
type(uint256).max amount and revert.type(uint256).max.[ ] [SOL-Token-FE-15] Can the token be paused?
[ ] [SOL-Token-FE-16] Is the decrease allowance feature of transferFrom() handled correctly when the sender is the caller?
[ ] [SOL-Token-NfE1-1] How are the minting and transfer implemented?
[ ] [SOL-Token-NfE1-2] Is the contract safe from reentrancy attack?
[ ] [SOL-Token-NfE1-3] Is the OpenZeppelin implementation of ERC721 and ERC1155 safeguarded against reentrancy attacks, especially in the safeTransferFrom functions?
safeTransferFrom functions in OpenZeppelin's ERC721 and ERC1155 can expose the contract to reentrancy attacks due to external calls to user addresses.[ ] [SOL-Token-NfE1-4] Is it possible to steal NFT abusing his approval?
from parameter of transferFrom() should be msg.sender. Otherwise an attacker can take advantage of other user's approvals and steal.msg.sender is actually the owner.[ ] [SOL-Token-NfE1-5] Does the ERC721/1155 contract correctly implement supportsInterface?
[ ] [SOL-Token-NfE1-6] Can the contract support both ERC721 and ERC1155 standards?
[ ] [SOL-Token-NfE1-7] What happens to the airdrops that are engaged to specific NFT?
[ ] [SOL-Token-NfE1-8] How is the approval/transfer handled for CryptoPunks collection?
transferFrom() function can present risks. The offerPunkForSaleToAddress() function in particular can be susceptible to front-running attacks, which can compromise the ownership and security of the token.testing
Specialist profile for mechanically applying the attack-vector deck and classifying vectors as skip, drop, or investigate.
tools
Specialist profile for libraries, helpers, base contracts, adapters, encoders, wrappers, and integration glue.
testing
Specialist profile for rounding, scale, decimal, downcast, and arithmetic accounting edge cases.
testing
Specialist profile for extracting conservation laws and state couplings, then searching for violating paths.