Aderyn Analysis Report
This report was generated by Aderyn, a static analysis tool built by Cyfrin, a blockchain security company. This report is not a substitute for manual audit or security review. It should not be relied upon for any purpose other than to assist in the identification of potential security vulnerabilities.
Table of Contents
- Summary
- High Issues
- Low Issues
- L-1: Centralization Risk for trusted owners
- L-2: Unsafe ERC20 Operations should not be used
- L-3: Solidity pragma should be specific, not wide
- L-4: Missing checks for
address(0)when assigning values to address state variables - L-5:
publicfunctions not used internally could be markedexternal - L-6: Define and use
constantvariables instead of using literals - L-7: Event is missing
indexedfields - L-8: The
nonReentrantmodifiershould occur before all other modifiers - L-9: PUSH0 is not supported by all chains
- L-10: Modifiers invoked only once can be shoe-horned into the function
- L-11: Large literal values multiples of 10000 can be replaced with scientific notation
- L-12: Unused Custom Error
- L-13: Redundant statements have no effect.
Summary
Files Summary
| Key | Value |
|---|---|
| .sol Files | 31 |
| Total nSLOC | 2989 |
Files Details
| Filepath | nSLOC |
|---|---|
| src/ERC20MintExtractor.sol | 24 |
| src/RWATokenCCT.sol | 153 |
| src/aa/TLPTPaymaster.sol | 200 |
| src/aa/TLPTPaymasterV2.sol | 386 |
| src/bridge/BridgeConsumer.sol | 40 |
| src/bridge/CrossChainBridge.sol | 102 |
| src/bridge/LockVault.sol | 67 |
| src/bridge/WrappedMBT.sol | 89 |
| src/bridge/WrappedMBTv2.sol | 135 |
| src/bridge/cre/CREBridgeConsumer.sol | 19 |
| src/bridge/cre/IReceiver.sol | 5 |
| src/bridge/cre/ReceiverTemplate.sol | 43 |
| src/defi/LendingVault.sol | 145 |
| src/defi/TestUSDC.sol | 45 |
| src/defi/YTMarket.sol | 94 |
| src/interfaces/ILendingVault.sol | 40 |
| src/interfaces/IYTMarket.sol | 26 |
| src/interfaces/IYieldIssuer.sol | 34 |
| src/issuance/CollateralRegistry.sol | 98 |
| src/issuance/IssuerRegistry.sol | 30 |
| src/issuance/RWATokenFactory.sol | 134 |
| src/policies/ComplianceCheck.sol | 89 |
| src/test-helpers/GasProbe.sol | 24 |
| src/tlpt/BridgeFeePool.sol | 160 |
| src/tlpt/OperatorAllowlist.sol | 66 |
| src/tlpt/OperatorRegistry.sol | 111 |
| src/tlpt/TLPTFaucet.sol | 85 |
| src/tlpt/TLPTSale.sol | 72 |
| src/tlpt/TLPTStaking.sol | 167 |
| src/yield/YieldIssuer.sol | 166 |
| src/yield/YieldToken.sol | 140 |
| Total | 2989 |
Issue Summary
| Category | No. of Issues |
|---|---|
| High | 4 |
| Low | 13 |
High Issues
H-1: Arbitrary from passed to transferFrom (or safeTransferFrom)
Passing an arbitrary from address to transferFrom (or safeTransferFrom) can lead to loss of funds, because anyone can transfer tokens from the from address if an approval is made.
2 Found Instances
- Found in src/aa/TLPTPaymaster.sol [Line: 236](src/aa/TLPTPaymaster.sol#L236) ```solidity tlpt.safeTransferFrom(user, address(this), tlptOwed); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 343](src/aa/TLPTPaymasterV2.sol#L343) ```solidity tlpt.safeTransferFrom(user, address(this), tlptOwed); ```H-2: Contract Name Reused in Different Files
When compiling contracts with certain development frameworks (for example: Truffle), having contracts with the same name across different files can lead to one being overwritten.
6 Found Instances
- Found in src/aa/TLPTPaymaster.sol [Line: 31](src/aa/TLPTPaymaster.sol#L31) ```solidity interface IEntryPoint { ``` - Found in src/aa/TLPTPaymaster.sol [Line: 40](src/aa/TLPTPaymaster.sol#L40) ```solidity interface IPaymaster { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 30](src/aa/TLPTPaymasterV2.sol#L30) ```solidity interface IEntryPoint { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 39](src/aa/TLPTPaymasterV2.sol#L39) ```solidity interface IPaymaster { ``` - Found in src/tlpt/TLPTFaucet.sol [Line: 6](src/tlpt/TLPTFaucet.sol#L6) ```solidity interface ITLPTMintable { ``` - Found in src/tlpt/TLPTSale.sol [Line: 9](src/tlpt/TLPTSale.sol#L9) ```solidity interface ITLPTMintable { ```H-3: Uninitialized State Variables
Solidity does initialize variables by default when you declare them, however it’s good practice to explicitly declare an initial value. For example, if you transfer money to an address we must make sure that the address has been initialized.
4 Found Instances
- Found in src/bridge/LockVault.sol [Line: 33](src/bridge/LockVault.sol#L33) ```solidity uint256 public lockNonce; ``` - Found in src/defi/LendingVault.sol [Line: 45](src/defi/LendingVault.sol#L45) ```solidity uint256 public nextPositionId; ``` - Found in src/defi/YTMarket.sol [Line: 42](src/defi/YTMarket.sol#L42) ```solidity uint256 public nextListingId; ``` - Found in src/yield/YieldIssuer.sol [Line: 71](src/yield/YieldIssuer.sol#L71) ```solidity uint256 public currentPeriodId; ```H-4: Contract locks Ether without a withdraw function.
It appears that the contract includes a payable function to accept Ether but lacks a corresponding function to withdraw it, which leads to the Ether being locked in the contract. To resolve this issue, please implement a public or external function that allows for the withdrawal of Ether from the contract.
2 Found Instances
- Found in src/aa/TLPTPaymaster.sol [Line: 69](src/aa/TLPTPaymaster.sol#L69) ```solidity contract TLPTPaymaster is IPaymaster, Ownable, ReentrancyGuard { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 84](src/aa/TLPTPaymasterV2.sol#L84) ```solidity contract TLPTPaymasterV2 is IPaymaster, Ownable, ReentrancyGuard { ```Low Issues
L-1: Centralization Risk for trusted owners
Contracts have owners with privileged rights to perform admin tasks and need to be trusted to not perform malicious updates or drain funds.
94 Found Instances
- Found in src/RWATokenCCT.sol [Line: 195](src/RWATokenCCT.sol#L195) ```solidity function setMintBurnAuthority(address authority, bool active) external onlyOwner { ``` - Found in src/RWATokenCCT.sol [Line: 209](src/RWATokenCCT.sol#L209) ```solidity function setReserveFeed(address newFeed) external onlyOwner { ``` - Found in src/RWATokenCCT.sol [Line: 215](src/RWATokenCCT.sol#L215) ```solidity function setMaxStaleness(uint256 newMaxStaleness) external onlyOwner { ``` - Found in src/aa/TLPTPaymaster.sol [Line: 69](src/aa/TLPTPaymaster.sol#L69) ```solidity contract TLPTPaymaster is IPaymaster, Ownable, ReentrancyGuard { ``` - Found in src/aa/TLPTPaymaster.sol [Line: 301](src/aa/TLPTPaymaster.sol#L301) ```solidity function setTlptPerEth(uint256 newPrice) external onlyOwner { ``` - Found in src/aa/TLPTPaymaster.sol [Line: 307](src/aa/TLPTPaymaster.sol#L307) ```solidity function setPriceMarkupBps(uint16 newBps) external onlyOwner { ``` - Found in src/aa/TLPTPaymaster.sol [Line: 313](src/aa/TLPTPaymaster.sol#L313) ```solidity function setMaxGasCostWei(uint256 newMax) external onlyOwner { ``` - Found in src/aa/TLPTPaymaster.sol [Line: 319](src/aa/TLPTPaymaster.sol#L319) ```solidity function setMaxBootstrapGasCostWei(uint256 newMax) external onlyOwner { ``` - Found in src/aa/TLPTPaymaster.sol [Line: 324](src/aa/TLPTPaymaster.sol#L324) ```solidity function setPaused(bool p) external onlyOwner { ``` - Found in src/aa/TLPTPaymaster.sol [Line: 338](src/aa/TLPTPaymaster.sol#L338) ```solidity function withdrawDeposit(address payable to, uint256 amount) external onlyOwner { ``` - Found in src/aa/TLPTPaymaster.sol [Line: 344](src/aa/TLPTPaymaster.sol#L344) ```solidity function withdrawTLPT(address to, uint256 amount) external onlyOwner { ``` - Found in src/aa/TLPTPaymaster.sol [Line: 350](src/aa/TLPTPaymaster.sol#L350) ```solidity function addStake(uint32 unstakeDelaySec) external payable onlyOwner { ``` - Found in src/aa/TLPTPaymaster.sol [Line: 354](src/aa/TLPTPaymaster.sol#L354) ```solidity function unlockStake() external onlyOwner { ``` - Found in src/aa/TLPTPaymaster.sol [Line: 358](src/aa/TLPTPaymaster.sol#L358) ```solidity function withdrawStake(address payable to) external onlyOwner { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 84](src/aa/TLPTPaymasterV2.sol#L84) ```solidity contract TLPTPaymasterV2 is IPaymaster, Ownable, ReentrancyGuard { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 528](src/aa/TLPTPaymasterV2.sol#L528) ```solidity function setNativeUSDFeed(AggregatorV3Interface feed) external onlyOwner { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 533](src/aa/TLPTPaymasterV2.sol#L533) ```solidity function setLinkUSDFeed(AggregatorV3Interface feed) external onlyOwner { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 538](src/aa/TLPTPaymasterV2.sol#L538) ```solidity function setTLPTUSDFeed(AggregatorV3Interface feed) external onlyOwner { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 543](src/aa/TLPTPaymasterV2.sol#L543) ```solidity function setNativeUSDFlat(uint256 newPrice) external onlyOwner { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 549](src/aa/TLPTPaymasterV2.sol#L549) ```solidity function setLinkUSDFlat(uint256 newPrice) external onlyOwner { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 561](src/aa/TLPTPaymasterV2.sol#L561) ```solidity function setTLPTUSDFlat(uint256 newPrice) external onlyOwner { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 586](src/aa/TLPTPaymasterV2.sol#L586) ```solidity function setMaxTlptPriceDeltaBps(uint16 newBps) external onlyOwner { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 592](src/aa/TLPTPaymasterV2.sol#L592) ```solidity function setTlptPriceMinInterval(uint256 newInterval) external onlyOwner { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 599](src/aa/TLPTPaymasterV2.sol#L599) ```solidity function setPriceMarkupBps(uint16 newBps) external onlyOwner { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 605](src/aa/TLPTPaymasterV2.sol#L605) ```solidity function setMaxGasCostWei(uint256 newMax) external onlyOwner { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 610](src/aa/TLPTPaymasterV2.sol#L610) ```solidity function setMaxLinkBudgetWei(uint256 newMax) external onlyOwner { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 615](src/aa/TLPTPaymasterV2.sol#L615) ```solidity function setMaxBootstrapGasCostWei(uint256 newMax) external onlyOwner { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 620](src/aa/TLPTPaymasterV2.sol#L620) ```solidity function setPaused(bool p) external onlyOwner { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 632](src/aa/TLPTPaymasterV2.sol#L632) ```solidity function withdrawDeposit(address payable to, uint256 amount) external onlyOwner { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 637](src/aa/TLPTPaymasterV2.sol#L637) ```solidity function withdrawTLPT(address to, uint256 amount) external onlyOwner { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 652](src/aa/TLPTPaymasterV2.sol#L652) ```solidity function withdrawLink(address to, uint256 amount) external onlyOwner { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 657](src/aa/TLPTPaymasterV2.sol#L657) ```solidity function addStake(uint32 unstakeDelaySec) external payable onlyOwner { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 661](src/aa/TLPTPaymasterV2.sol#L661) ```solidity function unlockStake() external onlyOwner { ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 665](src/aa/TLPTPaymasterV2.sol#L665) ```solidity function withdrawStake(address payable to) external onlyOwner { ``` - Found in src/bridge/BridgeConsumer.sol [Line: 26](src/bridge/BridgeConsumer.sol#L26) ```solidity contract BridgeConsumer is Ownable { ``` - Found in src/bridge/BridgeConsumer.sol [Line: 84](src/bridge/BridgeConsumer.sol#L84) ```solidity function setForwarder(address _forwarder) external onlyOwner { ``` - Found in src/bridge/BridgeConsumer.sol [Line: 91](src/bridge/BridgeConsumer.sol#L91) ```solidity function setWrappedToken(address _wrappedToken) external onlyOwner { ``` - Found in src/bridge/CrossChainBridge.sol [Line: 38](src/bridge/CrossChainBridge.sol#L38) ```solidity contract CrossChainBridge is FunctionsClient, Ownable { ``` - Found in src/bridge/CrossChainBridge.sol [Line: 135](src/bridge/CrossChainBridge.sol#L135) ```solidity function setFunctionsConfig(uint64 _subscriptionId, bytes32 _donId, uint32 _callbackGasLimit) external onlyOwner { ``` - Found in src/bridge/CrossChainBridge.sol [Line: 143](src/bridge/CrossChainBridge.sol#L143) ```solidity function setVerifyLockSource(string calldata _source) external onlyOwner { ``` - Found in src/bridge/CrossChainBridge.sol [Line: 149](src/bridge/CrossChainBridge.sol#L149) ```solidity function setSourceChainConfig(string calldata _rpcUrl, address _lockVault) external onlyOwner { ``` - Found in src/bridge/LockVault.sol [Line: 24](src/bridge/LockVault.sol#L24) ```solidity contract LockVault is Ownable { ``` - Found in src/bridge/LockVault.sol [Line: 124](src/bridge/LockVault.sol#L124) ```solidity function setBridgeOperator(address operator, bool active) external onlyOwner { ``` - Found in src/bridge/WrappedMBT.sol [Line: 19](src/bridge/WrappedMBT.sol#L19) ```solidity contract WrappedMBT is Ownable { ``` - Found in src/bridge/WrappedMBT.sol [Line: 146](src/bridge/WrappedMBT.sol#L146) ```solidity function setMinter(address minter, bool active) external onlyOwner { ``` - Found in src/bridge/WrappedMBTv2.sol [Line: 43](src/bridge/WrappedMBTv2.sol#L43) ```solidity contract WrappedMBTv2 is Ownable { ``` - Found in src/bridge/WrappedMBTv2.sol [Line: 198](src/bridge/WrappedMBTv2.sol#L198) ```solidity function setMinter(address minter, bool active) external onlyOwner { ``` - Found in src/bridge/WrappedMBTv2.sol [Line: 203](src/bridge/WrappedMBTv2.sol#L203) ```solidity function allowAddress(address account) external onlyOwner { ``` - Found in src/bridge/WrappedMBTv2.sol [Line: 210](src/bridge/WrappedMBTv2.sol#L210) ```solidity function disallowAddress(address account) external onlyOwner { ``` - Found in src/bridge/WrappedMBTv2.sol [Line: 219](src/bridge/WrappedMBTv2.sol#L219) ```solidity function allowAddresses(address[] calldata accounts) external onlyOwner { ``` - Found in src/bridge/WrappedMBTv2.sol [Line: 229](src/bridge/WrappedMBTv2.sol#L229) ```solidity function setPaused(bool _paused) external onlyOwner { ``` - Found in src/bridge/cre/ReceiverTemplate.sol [Line: 23](src/bridge/cre/ReceiverTemplate.sol#L23) ```solidity abstract contract ReceiverTemplate is IReceiver, Ownable { ``` - Found in src/bridge/cre/ReceiverTemplate.sol [Line: 46](src/bridge/cre/ReceiverTemplate.sol#L46) ```solidity function setForwarderAddress(address newForwarder) external onlyOwner { ``` - Found in src/issuance/CollateralRegistry.sol [Line: 24](src/issuance/CollateralRegistry.sol#L24) ```solidity contract CollateralRegistry is Ownable { ``` - Found in src/issuance/CollateralRegistry.sol [Line: 72](src/issuance/CollateralRegistry.sol#L72) ```solidity function setRegistrar(address registrar, bool active) external onlyOwner { ``` - Found in src/issuance/CollateralRegistry.sol [Line: 78](src/issuance/CollateralRegistry.sol#L78) ```solidity function setValuationUpdater(address updater, bool active) external onlyOwner { ``` - Found in src/issuance/IssuerRegistry.sol [Line: 21](src/issuance/IssuerRegistry.sol#L21) ```solidity contract IssuerRegistry is Ownable { ``` - Found in src/issuance/IssuerRegistry.sol [Line: 46](src/issuance/IssuerRegistry.sol#L46) ```solidity function approveIssuer(address issuer) external onlyOwner { ``` - Found in src/issuance/IssuerRegistry.sol [Line: 53](src/issuance/IssuerRegistry.sol#L53) ```solidity function revokeIssuer(address issuer) external onlyOwner { ``` - Found in src/issuance/IssuerRegistry.sol [Line: 59](src/issuance/IssuerRegistry.sol#L59) ```solidity function setAutoApprove(bool enabled) external onlyOwner { ``` - Found in src/policies/ComplianceCheck.sol [Line: 79](src/policies/ComplianceCheck.sol#L79) ```solidity function setPausedState(bool _paused) external onlyOwner { ``` - Found in src/policies/ComplianceCheck.sol [Line: 94](src/policies/ComplianceCheck.sol#L94) ```solidity function allowAddress(address account) external onlyOwner { ``` - Found in src/policies/ComplianceCheck.sol [Line: 101](src/policies/ComplianceCheck.sol#L101) ```solidity function disallowAddress(address account) external onlyOwner { ``` - Found in src/policies/ComplianceCheck.sol [Line: 110](src/policies/ComplianceCheck.sol#L110) ```solidity function allowAddresses(address[] calldata accounts) external onlyOwner { ``` - Found in src/tlpt/BridgeFeePool.sol [Line: 47](src/tlpt/BridgeFeePool.sol#L47) ```solidity contract BridgeFeePool is Ownable, ReentrancyGuard { ``` - Found in src/tlpt/BridgeFeePool.sol [Line: 243](src/tlpt/BridgeFeePool.sol#L243) ```solidity function setTlptPriceUSD(uint256 newPrice) external onlyOwner { ``` - Found in src/tlpt/BridgeFeePool.sol [Line: 249](src/tlpt/BridgeFeePool.sol#L249) ```solidity function setAttester(address newAttester) external onlyOwner { ``` - Found in src/tlpt/BridgeFeePool.sol [Line: 255](src/tlpt/BridgeFeePool.sol#L255) ```solidity function setTreasury(address newTreasury) external onlyOwner { ``` - Found in src/tlpt/BridgeFeePool.sol [Line: 261](src/tlpt/BridgeFeePool.sol#L261) ```solidity function setOperatorBps(uint256 newBps) external onlyOwner { ``` - Found in src/tlpt/BridgeFeePool.sol [Line: 267](src/tlpt/BridgeFeePool.sol#L267) ```solidity function setRefundTimeout(uint256 newTimeout) external onlyOwner { ``` - Found in src/tlpt/OperatorAllowlist.sol [Line: 35](src/tlpt/OperatorAllowlist.sol#L35) ```solidity contract OperatorAllowlist is Ownable { ``` - Found in src/tlpt/OperatorAllowlist.sol [Line: 74](src/tlpt/OperatorAllowlist.sol#L74) ```solidity function approve(address operator) external onlyOwner { ``` - Found in src/tlpt/OperatorAllowlist.sol [Line: 85](src/tlpt/OperatorAllowlist.sol#L85) ```solidity function approveMany(address[] calldata ops) external onlyOwner { ``` - Found in src/tlpt/OperatorAllowlist.sol [Line: 100](src/tlpt/OperatorAllowlist.sol#L100) ```solidity function unapprove(address operator) external onlyOwner { ``` - Found in src/tlpt/OperatorAllowlist.sol [Line: 107](src/tlpt/OperatorAllowlist.sol#L107) ```solidity function setMinStake(uint256 newMinStake) external onlyOwner { ``` - Found in src/tlpt/OperatorRegistry.sol [Line: 23](src/tlpt/OperatorRegistry.sol#L23) ```solidity contract OperatorRegistry is Ownable, ReentrancyGuard { ``` - Found in src/tlpt/OperatorRegistry.sol [Line: 137](src/tlpt/OperatorRegistry.sol#L137) ```solidity function slash(address operator, uint256 amount, string calldata reason) external onlyOwner nonReentrant { ``` - Found in src/tlpt/OperatorRegistry.sol [Line: 150](src/tlpt/OperatorRegistry.sol#L150) ```solidity function setStatReporter(address reporter, bool allowed) external onlyOwner { ``` - Found in src/tlpt/OperatorRegistry.sol [Line: 156](src/tlpt/OperatorRegistry.sol#L156) ```solidity function setTreasury(address newTreasury) external onlyOwner { ``` - Found in src/tlpt/TLPTFaucet.sol [Line: 31](src/tlpt/TLPTFaucet.sol#L31) ```solidity contract TLPTFaucet is Ownable { ``` - Found in src/tlpt/TLPTFaucet.sol [Line: 144](src/tlpt/TLPTFaucet.sol#L144) ```solidity function setClaimAmount(uint256 newAmount) external onlyOwner { ``` - Found in src/tlpt/TLPTFaucet.sol [Line: 150](src/tlpt/TLPTFaucet.sol#L150) ```solidity function setCooldown(uint256 newCooldown) external onlyOwner { ``` - Found in src/tlpt/TLPTFaucet.sol [Line: 155](src/tlpt/TLPTFaucet.sol#L155) ```solidity function setPaused(bool _paused) external onlyOwner { ``` - Found in src/tlpt/TLPTFaucet.sol [Line: 163](src/tlpt/TLPTFaucet.sol#L163) ```solidity function mintTo(address to, uint256 amount) external onlyOwner { ``` - Found in src/tlpt/TLPTSale.sol [Line: 33](src/tlpt/TLPTSale.sol#L33) ```solidity contract TLPTSale is Ownable, ReentrancyGuard { ``` - Found in src/tlpt/TLPTSale.sol [Line: 122](src/tlpt/TLPTSale.sol#L122) ```solidity function setPrice(uint256 newPriceUSD) external onlyOwner { ``` - Found in src/tlpt/TLPTSale.sol [Line: 128](src/tlpt/TLPTSale.sol#L128) ```solidity function setPaused(bool _paused) external onlyOwner { ``` - Found in src/tlpt/TLPTSale.sol [Line: 136](src/tlpt/TLPTSale.sol#L136) ```solidity function sweep(address to, uint256 amount) external onlyOwner nonReentrant { ``` - Found in src/tlpt/TLPTSale.sol [Line: 145](src/tlpt/TLPTSale.sol#L145) ```solidity function sweepAll(address to) external onlyOwner nonReentrant { ``` - Found in src/tlpt/TLPTStaking.sol [Line: 43](src/tlpt/TLPTStaking.sol#L43) ```solidity contract TLPTStaking is Ownable, ReentrancyGuard { ``` - Found in src/tlpt/TLPTStaking.sol [Line: 330](src/tlpt/TLPTStaking.sol#L330) ```solidity onlyOwner ``` - Found in src/yield/YieldToken.sol [Line: 212](src/yield/YieldToken.sol#L212) ```solidity function setCCIPAdmin(address newAdmin) external onlyOwner { ``` - Found in src/yield/YieldToken.sol [Line: 221](src/yield/YieldToken.sol#L221) ```solidity function setMintBurnAuthority(address authority, bool active) external onlyOwner { ``` - Found in src/yield/YieldToken.sol [Line: 226](src/yield/YieldToken.sol#L226) ```solidity function transferOwnership(address newOwner) external onlyOwner { ```L-2: Unsafe ERC20 Operations should not be used
ERC20 functions may not behave as expected. For example: return values are not always meaningful. It is recommended to use OpenZeppelin’s SafeERC20 library.
6 Found Instances
- Found in src/issuance/RWATokenFactory.sol [Line: 162](src/issuance/RWATokenFactory.sol#L162) ```solidity sels[0] = IERC20.transfer.selector; ``` - Found in src/issuance/RWATokenFactory.sol [Line: 163](src/issuance/RWATokenFactory.sol#L163) ```solidity sels[1] = IERC20.transferFrom.selector; ``` - Found in src/issuance/RWATokenFactory.sol [Line: 181](src/issuance/RWATokenFactory.sol#L181) ```solidity engine.addPolicy(s.token, IERC20.transfer.selector, s.allow, fromTo); ``` - Found in src/issuance/RWATokenFactory.sol [Line: 182](src/issuance/RWATokenFactory.sol#L182) ```solidity engine.addPolicy(s.token, IERC20.transferFrom.selector, s.allow, fromTo); ``` - Found in src/issuance/RWATokenFactory.sol [Line: 186](src/issuance/RWATokenFactory.sol#L186) ```solidity engine.addPolicy(s.token, IERC20.transfer.selector, s.pause, noParams); ``` - Found in src/issuance/RWATokenFactory.sol [Line: 187](src/issuance/RWATokenFactory.sol#L187) ```solidity engine.addPolicy(s.token, IERC20.transferFrom.selector, s.pause, noParams); ```L-3: Solidity pragma should be specific, not wide
Consider using a specific version of Solidity in your contracts instead of a wide version. For example, instead of pragma solidity ^0.8.0;, use pragma solidity 0.8.0;
31 Found Instances
- Found in src/ERC20MintExtractor.sol [Line: 2](src/ERC20MintExtractor.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/RWATokenCCT.sol [Line: 2](src/RWATokenCCT.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/aa/TLPTPaymaster.sol [Line: 2](src/aa/TLPTPaymaster.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 2](src/aa/TLPTPaymasterV2.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/bridge/BridgeConsumer.sol [Line: 2](src/bridge/BridgeConsumer.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/bridge/CrossChainBridge.sol [Line: 2](src/bridge/CrossChainBridge.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/bridge/LockVault.sol [Line: 2](src/bridge/LockVault.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/bridge/WrappedMBT.sol [Line: 2](src/bridge/WrappedMBT.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/bridge/WrappedMBTv2.sol [Line: 2](src/bridge/WrappedMBTv2.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/bridge/cre/CREBridgeConsumer.sol [Line: 2](src/bridge/cre/CREBridgeConsumer.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/bridge/cre/IReceiver.sol [Line: 2](src/bridge/cre/IReceiver.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/bridge/cre/ReceiverTemplate.sol [Line: 2](src/bridge/cre/ReceiverTemplate.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/defi/LendingVault.sol [Line: 2](src/defi/LendingVault.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/defi/TestUSDC.sol [Line: 2](src/defi/TestUSDC.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/defi/YTMarket.sol [Line: 2](src/defi/YTMarket.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/interfaces/ILendingVault.sol [Line: 2](src/interfaces/ILendingVault.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/interfaces/IYTMarket.sol [Line: 2](src/interfaces/IYTMarket.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/interfaces/IYieldIssuer.sol [Line: 2](src/interfaces/IYieldIssuer.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/issuance/CollateralRegistry.sol [Line: 2](src/issuance/CollateralRegistry.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/issuance/IssuerRegistry.sol [Line: 2](src/issuance/IssuerRegistry.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/issuance/RWATokenFactory.sol [Line: 2](src/issuance/RWATokenFactory.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/policies/ComplianceCheck.sol [Line: 2](src/policies/ComplianceCheck.sol#L2) ```solidity pragma solidity ^0.8.20; ``` - Found in src/test-helpers/GasProbe.sol [Line: 2](src/test-helpers/GasProbe.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/tlpt/BridgeFeePool.sol [Line: 2](src/tlpt/BridgeFeePool.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/tlpt/OperatorAllowlist.sol [Line: 2](src/tlpt/OperatorAllowlist.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/tlpt/OperatorRegistry.sol [Line: 2](src/tlpt/OperatorRegistry.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/tlpt/TLPTFaucet.sol [Line: 2](src/tlpt/TLPTFaucet.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/tlpt/TLPTSale.sol [Line: 2](src/tlpt/TLPTSale.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/tlpt/TLPTStaking.sol [Line: 2](src/tlpt/TLPTStaking.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/yield/YieldIssuer.sol [Line: 2](src/yield/YieldIssuer.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/yield/YieldToken.sol [Line: 2](src/yield/YieldToken.sol#L2) ```solidity pragma solidity ^0.8.24; ```L-4: Missing checks for address(0) when assigning values to address state variables
Check for address(0) when assigning values to address state variables.
13 Found Instances
- Found in src/RWATokenCCT.sol [Line: 211](src/RWATokenCCT.sol#L211) ```solidity reserveFeed = AggregatorV3Interface(newFeed); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 529](src/aa/TLPTPaymasterV2.sol#L529) ```solidity nativeUSDFeed = feed; ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 534](src/aa/TLPTPaymasterV2.sol#L534) ```solidity linkUSDFeed = feed; ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 539](src/aa/TLPTPaymasterV2.sol#L539) ```solidity tlptUSDFeed = feed; ``` - Found in src/bridge/BridgeConsumer.sol [Line: 51](src/bridge/BridgeConsumer.sol#L51) ```solidity wrappedToken = IWrappedMBT(_wrappedToken); ``` - Found in src/bridge/BridgeConsumer.sol [Line: 52](src/bridge/BridgeConsumer.sol#L52) ```solidity forwarder = _forwarder; ``` - Found in src/bridge/BridgeConsumer.sol [Line: 86](src/bridge/BridgeConsumer.sol#L86) ```solidity forwarder = _forwarder; ``` - Found in src/bridge/BridgeConsumer.sol [Line: 92](src/bridge/BridgeConsumer.sol#L92) ```solidity wrappedToken = IWrappedMBT(_wrappedToken); ``` - Found in src/bridge/CrossChainBridge.sol [Line: 77](src/bridge/CrossChainBridge.sol#L77) ```solidity wrappedToken = WrappedMBT(_wrappedToken); ``` - Found in src/bridge/CrossChainBridge.sol [Line: 151](src/bridge/CrossChainBridge.sol#L151) ```solidity lockVaultAddress = _lockVault; ``` - Found in src/defi/TestUSDC.sol [Line: 24](src/defi/TestUSDC.sol#L24) ```solidity owner = _owner; ``` - Found in src/yield/YieldIssuer.sol [Line: 131](src/yield/YieldIssuer.sol#L131) ```solidity issuer = _issuer; ``` - Found in src/yield/YieldToken.sol [Line: 214](src/yield/YieldToken.sol#L214) ```solidity ccipAdmin = newAdmin; ```L-5: public functions not used internally could be marked external
Instead of marking a function as public, consider marking it as external if it is not used internally.
3 Found Instances
- Found in src/ERC20MintExtractor.sol [Line: 21](src/ERC20MintExtractor.sol#L21) ```solidity function extract(IPolicyEngine.Payload calldata payload) ``` - Found in src/RWATokenCCT.sol [Line: 186](src/RWATokenCCT.sol#L186) ```solidity function supportsInterface(bytes4 interfaceId) public view override(PolicyProtected) returns (bool) { ``` - Found in src/policies/ComplianceCheck.sol [Line: 125](src/policies/ComplianceCheck.sol#L125) ```solidity function run( ```L-6: Define and use constant variables instead of using literals
If the same constant literal value is used multiple times, create a constant state variable and reference it throughout the contract.
67 Found Instances
- Found in src/aa/TLPTPaymaster.sol [Line: 191](src/aa/TLPTPaymaster.sol#L191) ```solidity worstCaseTLPT = (worstCaseTLPT * (10_000 + priceMarkupBps)) / 10_000; ``` - Found in src/aa/TLPTPaymaster.sol [Line: 232](src/aa/TLPTPaymaster.sol#L232) ```solidity uint256 tlptOwed = (actualGasCost * priceAtValidate) / 1e18; ``` - Found in src/aa/TLPTPaymaster.sol [Line: 253](src/aa/TLPTPaymaster.sol#L253) ```solidity if (bytes4(callData[0:4]) != SIMPLE_ACCOUNT_EXECUTE_SELECTOR) return false; ``` - Found in src/aa/TLPTPaymaster.sol [Line: 256](src/aa/TLPTPaymaster.sol#L256) ```solidity address target = address(uint160(uint256(bytes32(callData[4:36])))); ``` - Found in src/aa/TLPTPaymaster.sol [Line: 260](src/aa/TLPTPaymaster.sol#L260) ```solidity if (uint256(bytes32(callData[36:68])) != 0) return false; ``` - Found in src/aa/TLPTPaymaster.sol [Line: 265](src/aa/TLPTPaymaster.sol#L265) ```solidity if (bytes4(callData[132:136]) != ERC20_APPROVE_SELECTOR) return false; ``` - Found in src/aa/TLPTPaymaster.sol [Line: 268](src/aa/TLPTPaymaster.sol#L268) ```solidity address spender = address(uint160(uint256(bytes32(callData[136:168])))); ``` - Found in src/aa/TLPTPaymaster.sol [Line: 278](src/aa/TLPTPaymaster.sol#L278) ```solidity return (weiAmount * tlptPerEth) / 1e18; ``` - Found in src/aa/TLPTPaymaster.sol [Line: 286](src/aa/TLPTPaymaster.sol#L286) ```solidity return (base * (10_000 + priceMarkupBps)) / 10_000; ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 288](src/aa/TLPTPaymasterV2.sol#L288) ```solidity worstCaseTLPT = (worstCaseTLPT * (10_000 + priceMarkupBps)) / 10_000; ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 412](src/aa/TLPTPaymasterV2.sol#L412) ```solidity if (bytes4(callData[0:4]) != SIMPLE_ACCOUNT_EXECUTE_SELECTOR) return false; ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 413](src/aa/TLPTPaymasterV2.sol#L413) ```solidity address target = address(uint160(uint256(bytes32(callData[4:36])))); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 415](src/aa/TLPTPaymasterV2.sol#L415) ```solidity if (uint256(bytes32(callData[36:68])) != 0) return false; ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 416](src/aa/TLPTPaymasterV2.sol#L416) ```solidity if (bytes4(callData[132:136]) != ERC20_APPROVE_SELECTOR) return false; ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 417](src/aa/TLPTPaymasterV2.sol#L417) ```solidity address spender = address(uint160(uint256(bytes32(callData[136:168])))); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 441](src/aa/TLPTPaymasterV2.sol#L441) ```solidity if (len == 52) return 0; ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 442](src/aa/TLPTPaymasterV2.sol#L442) ```solidity if (len != 84) revert PaymasterDataMalformed(); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 443](src/aa/TLPTPaymasterV2.sol#L443) ```solidity return uint256(bytes32(paymasterAndData[52:84])); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 490](src/aa/TLPTPaymasterV2.sol#L490) ```solidity uint256 gasUSD = (gasWei * nativeUSD) / 1e18; ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 491](src/aa/TLPTPaymasterV2.sol#L491) ```solidity uint256 linkUSDOwed = (linkWei * linkUSD) / 1e18; ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 494](src/aa/TLPTPaymasterV2.sol#L494) ```solidity return (totalUSD * 1e18) / tlptUSD; ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 509](src/aa/TLPTPaymasterV2.sol#L509) ```solidity return (base * (10_000 + priceMarkupBps)) / 10_000; ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 569](src/aa/TLPTPaymasterV2.sol#L569) ```solidity uint256 deltaBps = (absDelta * 10_000) / old; ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 587](src/aa/TLPTPaymasterV2.sol#L587) ```solidity require(newBps <= 10_000, "delta > 100%"); ``` - Found in src/bridge/CrossChainBridge.sol [Line: 95](src/bridge/CrossChainBridge.sol#L95) ```solidity string[] memory args = new string[](3); ``` - Found in src/bridge/CrossChainBridge.sol [Line: 165](src/bridge/CrossChainBridge.sol#L165) ```solidity temp /= 10; ``` - Found in src/bridge/CrossChainBridge.sol [Line: 170](src/bridge/CrossChainBridge.sol#L170) ```solidity buffer[digits] = bytes1(uint8(48 + uint256(value % 10))); ``` - Found in src/bridge/CrossChainBridge.sol [Line: 171](src/bridge/CrossChainBridge.sol#L171) ```solidity value /= 10; ``` - Found in src/bridge/CrossChainBridge.sol [Line: 184](src/bridge/CrossChainBridge.sol#L184) ```solidity str[3 + i * 2] = alphabet[uint8(data[i] & 0x0f)]; ``` - Found in src/bridge/cre/ReceiverTemplate.sol [Line: 86](src/bridge/cre/ReceiverTemplate.sol#L86) ```solidity require(metadata.length >= 62, "ReceiverTemplate: metadata too short"); ``` - Found in src/bridge/cre/ReceiverTemplate.sol [Line: 89](src/bridge/cre/ReceiverTemplate.sol#L89) ```solidity workflowId = bytes32(metadata[0:32]); ``` - Found in src/bridge/cre/ReceiverTemplate.sol [Line: 90](src/bridge/cre/ReceiverTemplate.sol#L90) ```solidity workflowName = bytes10(metadata[32:42]); ``` - Found in src/bridge/cre/ReceiverTemplate.sol [Line: 91](src/bridge/cre/ReceiverTemplate.sol#L91) ```solidity workflowOwner = address(bytes20(metadata[42:62])); ``` - Found in src/defi/LendingVault.sol [Line: 116](src/defi/LendingVault.sol#L116) ```solidity borrowAmount = (collateralAmount * tokenPriceUSD * ltvBps) / (1e18 * 10000); ``` - Found in src/defi/LendingVault.sol [Line: 162](src/defi/LendingVault.sol#L162) ```solidity uint256 interestOwed = (pos.borrowedUSDC * annualRateBps * elapsed) / (365 days * 10000); ``` - Found in src/defi/LendingVault.sol [Line: 210](src/defi/LendingVault.sol#L210) ```solidity return (collateralAmount * tokenPriceUSD * ltvBps) / (1e18 * 10000); ``` - Found in src/defi/LendingVault.sol [Line: 221](src/defi/LendingVault.sol#L221) ```solidity return (pos.collateralAmount * tokenPriceUSD) / 1e18; ``` - Found in src/defi/LendingVault.sol [Line: 228](src/defi/LendingVault.sol#L228) ```solidity uint256 colValue = (pos.collateralAmount * tokenPriceUSD) / 1e18; ``` - Found in src/defi/LendingVault.sol [Line: 229](src/defi/LendingVault.sol#L229) ```solidity return (colValue * 10000) / pos.borrowedUSDC; ``` - Found in src/defi/LendingVault.sol [Line: 238](src/defi/LendingVault.sol#L238) ```solidity return (pos.borrowedUSDC * annualRateBps * elapsed) / (365 days * 10000); ``` - Found in src/defi/YTMarket.sol [Line: 116](src/defi/YTMarket.sol#L116) ```solidity uint256 usdcCost = (ytAmount * listing.pricePerToken) / 1e18; ``` - Found in src/defi/YTMarket.sol [Line: 172](src/defi/YTMarket.sol#L172) ```solidity usdcCost = (ytAmount * listing.pricePerToken) / 1e18; ``` - Found in src/tlpt/BridgeFeePool.sol [Line: 134](src/tlpt/BridgeFeePool.sol#L134) ```solidity uint256 feeTLPT = (feeUSD * 1e18) / tlptPriceUSD; ``` - Found in src/tlpt/BridgeFeePool.sol [Line: 214](src/tlpt/BridgeFeePool.sol#L214) ```solidity uint256 slice = remaining > 10_000e18 ? 10_000e18 : remaining; ``` - Found in src/tlpt/BridgeFeePool.sol [Line: 220](src/tlpt/BridgeFeePool.sol#L220) ```solidity slice = remaining > 90_000e18 ? 90_000e18 : remaining; ``` - Found in src/tlpt/BridgeFeePool.sol [Line: 226](src/tlpt/BridgeFeePool.sol#L226) ```solidity slice = remaining > 900_000e18 ? 900_000e18 : remaining; ``` - Found in src/tlpt/BridgeFeePool.sol [Line: 238](src/tlpt/BridgeFeePool.sol#L238) ```solidity return (computeFeeUSD(notionalUSD) * 1e18) / tlptPriceUSD; ``` - Found in src/tlpt/TLPTSale.sol [Line: 90](src/tlpt/TLPTSale.sol#L90) ```solidity tlptAmount = (usdcAmount * 1e18) / priceUSD; ``` - Found in src/tlpt/TLPTSale.sol [Line: 108](src/tlpt/TLPTSale.sol#L108) ```solidity return (usdcAmount * 1e18) / priceUSD; ``` - Found in src/tlpt/TLPTSale.sol [Line: 115](src/tlpt/TLPTSale.sol#L115) ```solidity usdcCost = (tlptAmount * priceUSD + 1e18 - 1) / 1e18; ```L-7: Event is missing indexed fields
Index event fields make the field more quickly accessible to off-chain tools that parse events. However, note that each index field costs extra gas during emission, so it’s not necessarily best to index the maximum allowed per event (three fields). Each event should use three indexed fields if there are three or more fields, and gas usage is not particularly of concern for the events in question. If there are fewer than three fields, all of the fields should be indexed.
113 Found Instances
- Found in src/RWATokenCCT.sol [Line: 58](src/RWATokenCCT.sol#L58) ```solidity event MintBurnAuthoritySet(address indexed authority, bool active); ``` - Found in src/RWATokenCCT.sol [Line: 61](src/RWATokenCCT.sol#L61) ```solidity event MaxStalenessUpdated(uint256 oldValue, uint256 newValue); ``` - Found in src/aa/TLPTPaymaster.sol [Line: 116](src/aa/TLPTPaymaster.sol#L116) ```solidity event TLPTCharged(address indexed user, uint256 actualGasCostWei, uint256 tlptCharged); ``` - Found in src/aa/TLPTPaymaster.sol [Line: 117](src/aa/TLPTPaymaster.sol#L117) ```solidity event PriceUpdated(uint256 oldTlptPerEth, uint256 newTlptPerEth); ``` - Found in src/aa/TLPTPaymaster.sol [Line: 118](src/aa/TLPTPaymaster.sol#L118) ```solidity event MarkupUpdated(uint16 oldBps, uint16 newBps); ``` - Found in src/aa/TLPTPaymaster.sol [Line: 119](src/aa/TLPTPaymaster.sol#L119) ```solidity event MaxGasCostUpdated(uint256 oldMax, uint256 newMax); ``` - Found in src/aa/TLPTPaymaster.sol [Line: 120](src/aa/TLPTPaymaster.sol#L120) ```solidity event PausedSet(bool paused); ``` - Found in src/aa/TLPTPaymaster.sol [Line: 121](src/aa/TLPTPaymaster.sol#L121) ```solidity event DepositAdded(uint256 amount); ``` - Found in src/aa/TLPTPaymaster.sol [Line: 122](src/aa/TLPTPaymaster.sol#L122) ```solidity event DepositWithdrawn(address indexed to, uint256 amount); ``` - Found in src/aa/TLPTPaymaster.sol [Line: 123](src/aa/TLPTPaymaster.sol#L123) ```solidity event TLPTWithdrawn(address indexed to, uint256 amount); ``` - Found in src/aa/TLPTPaymaster.sol [Line: 124](src/aa/TLPTPaymaster.sol#L124) ```solidity event BootstrappedWallet(address indexed wallet, uint256 actualGasCostWei); ``` - Found in src/aa/TLPTPaymaster.sol [Line: 125](src/aa/TLPTPaymaster.sol#L125) ```solidity event MaxBootstrapGasCostUpdated(uint256 oldMax, uint256 newMax); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 159](src/aa/TLPTPaymasterV2.sol#L159) ```solidity event TLPTCharged(address indexed user, uint256 actualGasCostWei, uint256 actualLinkWei, uint256 tlptCharged); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 160](src/aa/TLPTPaymasterV2.sol#L160) ```solidity event LinkRequested(address indexed smartWallet, uint256 amount); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 161](src/aa/TLPTPaymasterV2.sol#L161) ```solidity event LinkReturned(address indexed smartWallet, uint256 amount); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 165](src/aa/TLPTPaymasterV2.sol#L165) ```solidity event NativeUSDFlatUpdated(uint256 oldPrice, uint256 newPrice); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 166](src/aa/TLPTPaymasterV2.sol#L166) ```solidity event LinkUSDFlatUpdated(uint256 oldPrice, uint256 newPrice); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 167](src/aa/TLPTPaymasterV2.sol#L167) ```solidity event TLPTUSDFlatUpdated(uint256 oldPrice, uint256 newPrice); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 168](src/aa/TLPTPaymasterV2.sol#L168) ```solidity event MarkupUpdated(uint16 oldBps, uint16 newBps); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 169](src/aa/TLPTPaymasterV2.sol#L169) ```solidity event MaxGasCostUpdated(uint256 oldMax, uint256 newMax); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 170](src/aa/TLPTPaymasterV2.sol#L170) ```solidity event MaxLinkBudgetUpdated(uint256 oldMax, uint256 newMax); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 171](src/aa/TLPTPaymasterV2.sol#L171) ```solidity event MaxBootstrapGasCostUpdated(uint256 oldMax, uint256 newMax); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 172](src/aa/TLPTPaymasterV2.sol#L172) ```solidity event MaxTlptPriceDeltaBpsUpdated(uint16 oldBps, uint16 newBps); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 173](src/aa/TLPTPaymasterV2.sol#L173) ```solidity event TlptPriceMinIntervalUpdated(uint256 oldInterval, uint256 newInterval); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 174](src/aa/TLPTPaymasterV2.sol#L174) ```solidity event PausedSet(bool paused); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 175](src/aa/TLPTPaymasterV2.sol#L175) ```solidity event DepositAdded(uint256 amount); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 176](src/aa/TLPTPaymasterV2.sol#L176) ```solidity event DepositWithdrawn(address indexed to, uint256 amount); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 177](src/aa/TLPTPaymasterV2.sol#L177) ```solidity event TLPTWithdrawn(address indexed to, uint256 amount); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 178](src/aa/TLPTPaymasterV2.sol#L178) ```solidity event LinkWithdrawn(address indexed to, uint256 amount); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 179](src/aa/TLPTPaymasterV2.sol#L179) ```solidity event LinkDeposited(address indexed from, uint256 amount); ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 180](src/aa/TLPTPaymasterV2.sol#L180) ```solidity event BootstrappedWallet(address indexed wallet, uint256 actualGasCostWei); ``` - Found in src/bridge/BridgeConsumer.sol [Line: 37](src/bridge/BridgeConsumer.sol#L37) ```solidity event MintExecuted(uint256 indexed lockNonce, address indexed recipient, uint256 amount); ``` - Found in src/bridge/CrossChainBridge.sol [Line: 64](src/bridge/CrossChainBridge.sol#L64) ```solidity event MintRequested(bytes32 indexed requestId, uint256 lockNonce, address requester); ``` - Found in src/bridge/CrossChainBridge.sol [Line: 65](src/bridge/CrossChainBridge.sol#L65) ```solidity event MintFulfilled(bytes32 indexed requestId, uint256 lockNonce, address to, uint256 amount); ``` - Found in src/bridge/CrossChainBridge.sol [Line: 66](src/bridge/CrossChainBridge.sol#L66) ```solidity event MintFailed(bytes32 indexed requestId, uint256 lockNonce, bytes error); ``` - Found in src/bridge/LockVault.sol [Line: 49](src/bridge/LockVault.sol#L49) ```solidity event Locked( ``` - Found in src/bridge/LockVault.sol [Line: 52](src/bridge/LockVault.sol#L52) ```solidity event Unlocked(uint256 indexed nonce, address indexed recipient, uint256 amount); ``` - Found in src/bridge/LockVault.sol [Line: 53](src/bridge/LockVault.sol#L53) ```solidity event BridgeOperatorSet(address indexed operator, bool active); ``` - Found in src/bridge/WrappedMBT.sol [Line: 35](src/bridge/WrappedMBT.sol#L35) ```solidity event Transfer(address indexed from, address indexed to, uint256 value); ``` - Found in src/bridge/WrappedMBT.sol [Line: 36](src/bridge/WrappedMBT.sol#L36) ```solidity event Approval(address indexed owner, address indexed spender, uint256 value); ``` - Found in src/bridge/WrappedMBT.sol [Line: 37](src/bridge/WrappedMBT.sol#L37) ```solidity event MinterSet(address indexed minter, bool active); ``` - Found in src/bridge/WrappedMBT.sol [Line: 38](src/bridge/WrappedMBT.sol#L38) ```solidity event BridgeMint(uint256 indexed lockNonce, address indexed to, uint256 amount); ``` - Found in src/bridge/WrappedMBT.sol [Line: 39](src/bridge/WrappedMBT.sol#L39) ```solidity event BridgeBurn(address indexed from, uint256 amount, uint256 srcChainId, uint256 lockNonce); ``` - Found in src/bridge/WrappedMBTv2.sol [Line: 66](src/bridge/WrappedMBTv2.sol#L66) ```solidity event Transfer(address indexed from, address indexed to, uint256 value); ``` - Found in src/bridge/WrappedMBTv2.sol [Line: 67](src/bridge/WrappedMBTv2.sol#L67) ```solidity event Approval(address indexed owner, address indexed spender, uint256 value); ``` - Found in src/bridge/WrappedMBTv2.sol [Line: 68](src/bridge/WrappedMBTv2.sol#L68) ```solidity event MinterSet(address indexed minter, bool active); ``` - Found in src/bridge/WrappedMBTv2.sol [Line: 69](src/bridge/WrappedMBTv2.sol#L69) ```solidity event AllowlistSet(address indexed account, bool allowed); ``` - Found in src/bridge/WrappedMBTv2.sol [Line: 70](src/bridge/WrappedMBTv2.sol#L70) ```solidity event PausedSet(bool paused); ``` - Found in src/bridge/WrappedMBTv2.sol [Line: 71](src/bridge/WrappedMBTv2.sol#L71) ```solidity event BridgeMint(uint256 indexed lockNonce, address indexed to, uint256 amount); ``` - Found in src/bridge/WrappedMBTv2.sol [Line: 72](src/bridge/WrappedMBTv2.sol#L72) ```solidity event BridgeBurn(address indexed from, uint256 amount, uint256 srcChainId, uint256 lockNonce); ``` - Found in src/bridge/cre/CREBridgeConsumer.sol [Line: 37](src/bridge/cre/CREBridgeConsumer.sol#L37) ```solidity event BridgeMintExecuted(address indexed recipient, uint256 amount, uint256 lockNonce); ``` - Found in src/bridge/cre/ReceiverTemplate.sol [Line: 29](src/bridge/cre/ReceiverTemplate.sol#L29) ```solidity event ReportReceived(bytes32 indexed workflowId, bytes10 workflowName, address indexed workflowOwner); ``` - Found in src/defi/LendingVault.sol [Line: 53](src/defi/LendingVault.sol#L53) ```solidity event PositionOpened(uint256 indexed positionId, address indexed borrower, uint256 collateral, uint256 borrowed); ``` - Found in src/defi/LendingVault.sol [Line: 54](src/defi/LendingVault.sol#L54) ```solidity event PositionRepaid( ``` - Found in src/defi/LendingVault.sol [Line: 57](src/defi/LendingVault.sol#L57) ```solidity event InterestCharged(uint256 indexed positionId, uint256 interestPaid); ``` - Found in src/defi/LendingVault.sol [Line: 58](src/defi/LendingVault.sol#L58) ```solidity event PriceUpdated(uint256 oldPrice, uint256 newPrice); ``` - Found in src/defi/LendingVault.sol [Line: 59](src/defi/LendingVault.sol#L59) ```solidity event LTVUpdated(uint256 oldLtv, uint256 newLtv); ``` - Found in src/defi/TestUSDC.sol [Line: 20](src/defi/TestUSDC.sol#L20) ```solidity event Transfer(address indexed from, address indexed to, uint256 value); ``` - Found in src/defi/TestUSDC.sol [Line: 21](src/defi/TestUSDC.sol#L21) ```solidity event Approval(address indexed owner, address indexed spender, uint256 value); ``` - Found in src/defi/YTMarket.sol [Line: 49](src/defi/YTMarket.sol#L49) ```solidity event Listed(uint256 indexed listingId, address indexed seller, uint256 ytAmount, uint256 pricePerToken); ``` - Found in src/defi/YTMarket.sol [Line: 50](src/defi/YTMarket.sol#L50) ```solidity event Bought(uint256 indexed listingId, address indexed buyer, uint256 ytAmount, uint256 usdcPaid); ``` - Found in src/defi/YTMarket.sol [Line: 51](src/defi/YTMarket.sol#L51) ```solidity event Cancelled(uint256 indexed listingId, address indexed seller, uint256 ytReturned); ``` - Found in src/interfaces/ILendingVault.sol [Line: 25](src/interfaces/ILendingVault.sol#L25) ```solidity event PositionOpened(uint256 indexed positionId, address indexed borrower, uint256 collateral, uint256 borrowed); ``` - Found in src/interfaces/ILendingVault.sol [Line: 26](src/interfaces/ILendingVault.sol#L26) ```solidity event PositionRepaid( ``` - Found in src/interfaces/ILendingVault.sol [Line: 29](src/interfaces/ILendingVault.sol#L29) ```solidity event PriceUpdated(uint256 oldPrice, uint256 newPrice); ``` - Found in src/interfaces/ILendingVault.sol [Line: 30](src/interfaces/ILendingVault.sol#L30) ```solidity event LTVUpdated(uint256 oldLtv, uint256 newLtv); ``` - Found in src/interfaces/IYTMarket.sol [Line: 16](src/interfaces/IYTMarket.sol#L16) ```solidity event Listed(uint256 indexed listingId, address indexed seller, uint256 ytAmount, uint256 pricePerToken); ``` - Found in src/interfaces/IYTMarket.sol [Line: 17](src/interfaces/IYTMarket.sol#L17) ```solidity event Bought(uint256 indexed listingId, address indexed buyer, uint256 ytAmount, uint256 usdcPaid); ``` - Found in src/interfaces/IYTMarket.sol [Line: 18](src/interfaces/IYTMarket.sol#L18) ```solidity event Cancelled(uint256 indexed listingId, address indexed seller, uint256 ytReturned); ``` - Found in src/interfaces/IYieldIssuer.sol [Line: 20](src/interfaces/IYieldIssuer.sol#L20) ```solidity event PeriodStarted(uint256 indexed periodId, uint256 startTime); ``` - Found in src/interfaces/IYieldIssuer.sol [Line: 21](src/interfaces/IYieldIssuer.sol#L21) ```solidity event PeriodEnded(uint256 indexed periodId, uint256 endTime); ``` - Found in src/interfaces/IYieldIssuer.sol [Line: 22](src/interfaces/IYieldIssuer.sol#L22) ```solidity event YieldDeposited(uint256 indexed periodId, uint256 amount, uint256 ytSupplyAtDeposit); ``` - Found in src/interfaces/IYieldIssuer.sol [Line: 23](src/interfaces/IYieldIssuer.sol#L23) ```solidity event YieldTokensMinted(uint256 indexed periodId, address indexed holder, uint256 amount); ``` - Found in src/interfaces/IYieldIssuer.sol [Line: 24](src/interfaces/IYieldIssuer.sol#L24) ```solidity event YieldClaimed(uint256 indexed periodId, address indexed holder, uint256 amount); ``` - Found in src/issuance/CollateralRegistry.sol [Line: 44](src/issuance/CollateralRegistry.sol#L44) ```solidity event RegistrarSet(address indexed registrar, bool active); ``` - Found in src/issuance/CollateralRegistry.sol [Line: 45](src/issuance/CollateralRegistry.sol#L45) ```solidity event ValuationUpdaterSet(address indexed updater, bool active); ``` - Found in src/issuance/CollateralRegistry.sol [Line: 46](src/issuance/CollateralRegistry.sol#L46) ```solidity event CollateralRegistered(address indexed token, address indexed issuer, bytes32 assetId); ``` - Found in src/issuance/CollateralRegistry.sol [Line: 47](src/issuance/CollateralRegistry.sol#L47) ```solidity event ValuationUpdated(address indexed token, uint256 valuationUSD); ``` - Found in src/issuance/CollateralRegistry.sol [Line: 48](src/issuance/CollateralRegistry.sol#L48) ```solidity event CollateralActiveSet(address indexed token, bool active); ``` - Found in src/issuance/IssuerRegistry.sol [Line: 30](src/issuance/IssuerRegistry.sol#L30) ```solidity event AutoApproveSet(bool enabled); ``` - Found in src/tlpt/BridgeFeePool.sol [Line: 75](src/tlpt/BridgeFeePool.sol#L75) ```solidity event FeeCollected(uint256 indexed lockNonce, address indexed user, uint256 notionalUSD, uint256 feeTLPT); ``` - Found in src/tlpt/BridgeFeePool.sol [Line: 77](src/tlpt/BridgeFeePool.sol#L77) ```solidity event PayoutClaimed( ``` - Found in src/tlpt/BridgeFeePool.sol [Line: 80](src/tlpt/BridgeFeePool.sol#L80) ```solidity event Refunded(uint256 indexed lockNonce, address indexed user, uint256 amount); ``` - Found in src/tlpt/BridgeFeePool.sol [Line: 81](src/tlpt/BridgeFeePool.sol#L81) ```solidity event TlptPriceUpdated(uint256 newPrice); ``` - Found in src/tlpt/BridgeFeePool.sol [Line: 84](src/tlpt/BridgeFeePool.sol#L84) ```solidity event OperatorBpsUpdated(uint256 newBps); ``` - Found in src/tlpt/BridgeFeePool.sol [Line: 85](src/tlpt/BridgeFeePool.sol#L85) ```solidity event RefundTimeoutUpdated(uint256 newTimeout); ``` - Found in src/tlpt/OperatorAllowlist.sol [Line: 58](src/tlpt/OperatorAllowlist.sol#L58) ```solidity event MinStakeUpdated(uint256 newMinStake); ``` - Found in src/tlpt/OperatorRegistry.sol [Line: 50](src/tlpt/OperatorRegistry.sol#L50) ```solidity event Registered(address indexed operator, uint256 stake); ``` - Found in src/tlpt/OperatorRegistry.sol [Line: 51](src/tlpt/OperatorRegistry.sol#L51) ```solidity event Deregistered(address indexed operator, uint256 cooldownEnd); ``` - Found in src/tlpt/OperatorRegistry.sol [Line: 52](src/tlpt/OperatorRegistry.sol#L52) ```solidity event Withdrawn(address indexed operator, uint256 amount); ``` - Found in src/tlpt/OperatorRegistry.sol [Line: 53](src/tlpt/OperatorRegistry.sol#L53) ```solidity event Slashed(address indexed operator, uint256 amount, string reason); ``` - Found in src/tlpt/OperatorRegistry.sol [Line: 54](src/tlpt/OperatorRegistry.sol#L54) ```solidity event PayoutRecorded(address indexed operator, uint256 feeAmount); ``` - Found in src/tlpt/OperatorRegistry.sol [Line: 55](src/tlpt/OperatorRegistry.sol#L55) ```solidity event StatReporterSet(address indexed reporter, bool allowed); ``` - Found in src/tlpt/TLPTFaucet.sol [Line: 50](src/tlpt/TLPTFaucet.sol#L50) ```solidity event Claimed(address indexed claimant, uint256 amount); ``` - Found in src/tlpt/TLPTFaucet.sol [Line: 51](src/tlpt/TLPTFaucet.sol#L51) ```solidity event ClaimedFor(address indexed caller, address indexed recipient, uint256 amount); ``` - Found in src/tlpt/TLPTFaucet.sol [Line: 52](src/tlpt/TLPTFaucet.sol#L52) ```solidity event ClaimAmountUpdated(uint256 newAmount); ``` - Found in src/tlpt/TLPTFaucet.sol [Line: 53](src/tlpt/TLPTFaucet.sol#L53) ```solidity event CooldownUpdated(uint256 newCooldown); ``` - Found in src/tlpt/TLPTFaucet.sol [Line: 54](src/tlpt/TLPTFaucet.sol#L54) ```solidity event PausedUpdated(bool paused); ``` - Found in src/tlpt/TLPTSale.sol [Line: 55](src/tlpt/TLPTSale.sol#L55) ```solidity event Bought(address indexed buyer, uint256 usdcPaid, uint256 tlptReceived); ``` - Found in src/tlpt/TLPTSale.sol [Line: 56](src/tlpt/TLPTSale.sol#L56) ```solidity event PriceUpdated(uint256 newPrice); ``` - Found in src/tlpt/TLPTSale.sol [Line: 57](src/tlpt/TLPTSale.sol#L57) ```solidity event PausedUpdated(bool paused); ``` - Found in src/tlpt/TLPTSale.sol [Line: 58](src/tlpt/TLPTSale.sol#L58) ```solidity event ProceedsSwept(address indexed to, uint256 amount); ``` - Found in src/tlpt/TLPTStaking.sol [Line: 88](src/tlpt/TLPTStaking.sol#L88) ```solidity event Staked(address indexed staker, uint256 amount, uint8 tier, uint40 lockedUntil); ``` - Found in src/tlpt/TLPTStaking.sol [Line: 89](src/tlpt/TLPTStaking.sol#L89) ```solidity event LockExtended(address indexed staker, uint8 oldTier, uint8 newTier, uint40 lockedUntil); ``` - Found in src/tlpt/TLPTStaking.sol [Line: 90](src/tlpt/TLPTStaking.sol#L90) ```solidity event UnstakeRequested(address indexed staker, uint256 amount, uint40 withdrawableAt); ``` - Found in src/tlpt/TLPTStaking.sol [Line: 91](src/tlpt/TLPTStaking.sol#L91) ```solidity event UnstakeCancelled(address indexed staker, uint256 amount); ``` - Found in src/tlpt/TLPTStaking.sol [Line: 92](src/tlpt/TLPTStaking.sol#L92) ```solidity event Withdrawn(address indexed staker, uint256 amount); ``` - Found in src/yield/YieldIssuer.sol [Line: 96](src/yield/YieldIssuer.sol#L96) ```solidity event PeriodStarted(uint256 indexed periodId, uint256 startTime); ``` - Found in src/yield/YieldIssuer.sol [Line: 97](src/yield/YieldIssuer.sol#L97) ```solidity event PeriodEnded(uint256 indexed periodId, uint256 endTime); ``` - Found in src/yield/YieldIssuer.sol [Line: 98](src/yield/YieldIssuer.sol#L98) ```solidity event YieldDeposited(uint256 indexed periodId, uint256 amount, uint256 ytSupply); ``` - Found in src/yield/YieldIssuer.sol [Line: 99](src/yield/YieldIssuer.sol#L99) ```solidity event YieldTokensMinted(uint256 indexed periodId, address indexed holder, uint256 amount); ``` - Found in src/yield/YieldIssuer.sol [Line: 100](src/yield/YieldIssuer.sol#L100) ```solidity event YieldClaimed(uint256 indexed periodId, address indexed holder, uint256 amount); ``` - Found in src/yield/YieldToken.sol [Line: 72](src/yield/YieldToken.sol#L72) ```solidity event MintBurnAuthoritySet(address indexed authority, bool active); ```L-8: The nonReentrant modifier should occur before all other modifiers
This is a best-practice to protect against reentrancy in other modifiers.
6 Found Instances
- Found in src/aa/TLPTPaymaster.sol [Line: 219](src/aa/TLPTPaymaster.sol#L219) ```solidity nonReentrant ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 313](src/aa/TLPTPaymasterV2.sol#L313) ```solidity nonReentrant ``` - Found in src/tlpt/OperatorRegistry.sol [Line: 137](src/tlpt/OperatorRegistry.sol#L137) ```solidity function slash(address operator, uint256 amount, string calldata reason) external onlyOwner nonReentrant { ``` - Found in src/tlpt/TLPTSale.sol [Line: 136](src/tlpt/TLPTSale.sol#L136) ```solidity function sweep(address to, uint256 amount) external onlyOwner nonReentrant { ``` - Found in src/tlpt/TLPTSale.sol [Line: 145](src/tlpt/TLPTSale.sol#L145) ```solidity function sweepAll(address to) external onlyOwner nonReentrant { ``` - Found in src/yield/YieldIssuer.sol [Line: 169](src/yield/YieldIssuer.sol#L169) ```solidity function depositYield(uint256 amount) external onlyIssuer nonReentrant { ```L-9: PUSH0 is not supported by all chains
Solc compiler version 0.8.20 switches the default target EVM version to Shanghai, which means that the generated bytecode will include PUSH0 opcodes. Be sure to select the appropriate EVM version in case you intend to deploy on a chain other than mainnet like L2 chains that may not support PUSH0, otherwise deployment of your contracts will fail.
31 Found Instances
- Found in src/ERC20MintExtractor.sol [Line: 2](src/ERC20MintExtractor.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/RWATokenCCT.sol [Line: 2](src/RWATokenCCT.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/aa/TLPTPaymaster.sol [Line: 2](src/aa/TLPTPaymaster.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 2](src/aa/TLPTPaymasterV2.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/bridge/BridgeConsumer.sol [Line: 2](src/bridge/BridgeConsumer.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/bridge/CrossChainBridge.sol [Line: 2](src/bridge/CrossChainBridge.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/bridge/LockVault.sol [Line: 2](src/bridge/LockVault.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/bridge/WrappedMBT.sol [Line: 2](src/bridge/WrappedMBT.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/bridge/WrappedMBTv2.sol [Line: 2](src/bridge/WrappedMBTv2.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/bridge/cre/CREBridgeConsumer.sol [Line: 2](src/bridge/cre/CREBridgeConsumer.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/bridge/cre/IReceiver.sol [Line: 2](src/bridge/cre/IReceiver.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/bridge/cre/ReceiverTemplate.sol [Line: 2](src/bridge/cre/ReceiverTemplate.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/defi/LendingVault.sol [Line: 2](src/defi/LendingVault.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/defi/TestUSDC.sol [Line: 2](src/defi/TestUSDC.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/defi/YTMarket.sol [Line: 2](src/defi/YTMarket.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/interfaces/ILendingVault.sol [Line: 2](src/interfaces/ILendingVault.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/interfaces/IYTMarket.sol [Line: 2](src/interfaces/IYTMarket.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/interfaces/IYieldIssuer.sol [Line: 2](src/interfaces/IYieldIssuer.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/issuance/CollateralRegistry.sol [Line: 2](src/issuance/CollateralRegistry.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/issuance/IssuerRegistry.sol [Line: 2](src/issuance/IssuerRegistry.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/issuance/RWATokenFactory.sol [Line: 2](src/issuance/RWATokenFactory.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/policies/ComplianceCheck.sol [Line: 2](src/policies/ComplianceCheck.sol#L2) ```solidity pragma solidity ^0.8.20; ``` - Found in src/test-helpers/GasProbe.sol [Line: 2](src/test-helpers/GasProbe.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/tlpt/BridgeFeePool.sol [Line: 2](src/tlpt/BridgeFeePool.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/tlpt/OperatorAllowlist.sol [Line: 2](src/tlpt/OperatorAllowlist.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/tlpt/OperatorRegistry.sol [Line: 2](src/tlpt/OperatorRegistry.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/tlpt/TLPTFaucet.sol [Line: 2](src/tlpt/TLPTFaucet.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/tlpt/TLPTSale.sol [Line: 2](src/tlpt/TLPTSale.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/tlpt/TLPTStaking.sol [Line: 2](src/tlpt/TLPTStaking.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/yield/YieldIssuer.sol [Line: 2](src/yield/YieldIssuer.sol#L2) ```solidity pragma solidity ^0.8.24; ``` - Found in src/yield/YieldToken.sol [Line: 2](src/yield/YieldToken.sol#L2) ```solidity pragma solidity ^0.8.24; ```L-10: Modifiers invoked only once can be shoe-horned into the function
7 Found Instances
- Found in src/bridge/BridgeConsumer.sol [Line: 45](src/bridge/BridgeConsumer.sol#L45) ```solidity modifier onlyForwarder() { ``` - Found in src/bridge/LockVault.sol [Line: 61](src/bridge/LockVault.sol#L61) ```solidity modifier onlyBridgeOperator() { ``` - Found in src/bridge/WrappedMBT.sol [Line: 48](src/bridge/WrappedMBT.sol#L48) ```solidity modifier onlyMinter() { ``` - Found in src/bridge/WrappedMBTv2.sol [Line: 83](src/bridge/WrappedMBTv2.sol#L83) ```solidity modifier onlyMinter() { ``` - Found in src/issuance/CollateralRegistry.sol [Line: 61](src/issuance/CollateralRegistry.sol#L61) ```solidity modifier onlyValuationUpdater() { ``` - Found in src/tlpt/BridgeFeePool.sol [Line: 102](src/tlpt/BridgeFeePool.sol#L102) ```solidity modifier onlyAttester() { ``` - Found in src/tlpt/OperatorRegistry.sol [Line: 68](src/tlpt/OperatorRegistry.sol#L68) ```solidity modifier onlyStatReporter() { ```L-11: Large literal values multiples of 10000 can be replaced with scientific notation
Use e notation, for example: 1e18, instead of its full numeric value.
22 Found Instances
- Found in src/aa/TLPTPaymaster.sol [Line: 191](src/aa/TLPTPaymaster.sol#L191) ```solidity worstCaseTLPT = (worstCaseTLPT * (10_000 + priceMarkupBps)) / 10_000; ``` - Found in src/aa/TLPTPaymaster.sol [Line: 286](src/aa/TLPTPaymaster.sol#L286) ```solidity return (base * (10_000 + priceMarkupBps)) / 10_000; ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 108](src/aa/TLPTPaymasterV2.sol#L108) ```solidity uint256 public constant TLPT_USD_FLOOR = 100_000; ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 110](src/aa/TLPTPaymasterV2.sol#L110) ```solidity uint256 public constant TLPT_USD_CEILING = 1_000_000_000; ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 288](src/aa/TLPTPaymasterV2.sol#L288) ```solidity worstCaseTLPT = (worstCaseTLPT * (10_000 + priceMarkupBps)) / 10_000; ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 509](src/aa/TLPTPaymasterV2.sol#L509) ```solidity return (base * (10_000 + priceMarkupBps)) / 10_000; ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 569](src/aa/TLPTPaymasterV2.sol#L569) ```solidity uint256 deltaBps = (absDelta * 10_000) / old; ``` - Found in src/aa/TLPTPaymasterV2.sol [Line: 587](src/aa/TLPTPaymasterV2.sol#L587) ```solidity require(newBps <= 10_000, "delta > 100%"); ``` - Found in src/bridge/CrossChainBridge.sol [Line: 46](src/bridge/CrossChainBridge.sol#L46) ```solidity uint32 public callbackGasLimit = 300_000; ``` - Found in src/defi/LendingVault.sol [Line: 116](src/defi/LendingVault.sol#L116) ```solidity borrowAmount = (collateralAmount * tokenPriceUSD * ltvBps) / (1e18 * 10000); ``` - Found in src/defi/LendingVault.sol [Line: 162](src/defi/LendingVault.sol#L162) ```solidity uint256 interestOwed = (pos.borrowedUSDC * annualRateBps * elapsed) / (365 days * 10000); ``` - Found in src/defi/LendingVault.sol [Line: 210](src/defi/LendingVault.sol#L210) ```solidity return (collateralAmount * tokenPriceUSD * ltvBps) / (1e18 * 10000); ``` - Found in src/defi/LendingVault.sol [Line: 229](src/defi/LendingVault.sol#L229) ```solidity return (colValue * 10000) / pos.borrowedUSDC; ``` - Found in src/defi/LendingVault.sol [Line: 238](src/defi/LendingVault.sol#L238) ```solidity return (pos.borrowedUSDC * annualRateBps * elapsed) / (365 days * 10000); ``` - Found in src/tlpt/BridgeFeePool.sol [Line: 61](src/tlpt/BridgeFeePool.sol#L61) ```solidity uint256 public constant BPS_DENOMINATOR = 10_000; ``` - Found in src/tlpt/TLPTStaking.sol [Line: 59](src/tlpt/TLPTStaking.sol#L59) ```solidity uint256 public constant MULTIPLIER_BASIS = 10000; ``` - Found in src/tlpt/TLPTStaking.sol [Line: 116](src/tlpt/TLPTStaking.sol#L116) ```solidity multipliersBps[0] = 10000; // 1.00x ``` - Found in src/tlpt/TLPTStaking.sol [Line: 119](src/tlpt/TLPTStaking.sol#L119) ```solidity multipliersBps[3] = 20000; // 2.00x ```L-12: Unused Custom Error
it is recommended that the definition be removed when custom error is unused
1 Found Instances
- Found in src/aa/TLPTPaymaster.sol [Line: 134](src/aa/TLPTPaymaster.sol#L134) ```solidity error WalletAlreadyBootstrapped(address wallet); ```L-13: Redundant statements have no effect.
Remove the redundant statements because no code will be generated and it just congests the codebase.