Skip to content

In-depth lesson · Business logic

Root causes

Every point the Business logic reports back under this heading, best-backed first, each with the reports it is seen in.

Back to the lesson 651 to 700 of 5,700
  1. A staging subdomain retained an open registration endpoint and the invitation flow used a hardcoded localhost redirect.

    Seen in 1 report
  2. A stale previous-block score was used when subtracting the governance delta after a user lost eligibility.

    Seen in 1 report
  3. A stale workaround in the permission message provider removed the New Tab Page override permission from both comparison sets, so adding that override was never treated as a privilege increase.

    Seen in 1 report
  4. A state-changing function lacks the checkpoint modifier, so balance changes never propagate to the votes contract.

    Seen in 1 report
  5. A stateful custom fee collector is paired with a generic weight benchmarked without it.

    Seen in 1 report
  6. A static flag makes the captcha check run only once per request and later calls return true.

    Seen in 1 report
  7. A static share amount per user was combined with a rebasing total supply, so the ratio drifted as interest accrued.

    Seen in 1 report
  8. A staticcall is used to invoke a gauge function that writes to storage, so it always reverts and returns zero.

    Seen in 1 report
  9. A stopped state variable is set but never read, and the closed check is hardcoded to return false, so the pause logic is disabled.

    Seen in 1 report
  10. A strict equality check between the live token balance and tracked collateral minus loss can be broken by unsolicited transfers.

    Seen in 1 report
  11. A strict greater-than check against a minimum of zero rejects the boundary value.

    Seen in 1 report
  12. A strict greater-than comparison excludes the valid boundary value of the health factor.

    Seen in 1 report
  13. A strict greater-than comparison is used where greater-than-or-equal is needed, so equal shares and assets block the rollover.

    Seen in 1 report
  14. A strict greater-than-or-equal check skips clearing entirely instead of clearing the maximum possible amount.

    Seen in 1 report
  15. A strict less-than comparison was used instead of less-than-or-equal when checking whether the current time is still inside the reward epoch, mishandling the boundary.

    Seen in 1 report
  16. A strict less-than length check rejected the maximum value.

    Seen in 1 report
  17. A struct variable was assigned by reference rather than copied, so later modifications to the original also changed the supposed copy.

    Seen in 1 report
  18. A subaccount was only added to the vault's internal list when an order filled, so posted collateral was excluded from total assets.

    Seen in 1 report
  19. A subtraction in settlement could underflow when the bonded amount exceeded the other operand, which happens with late bonding or small multiplier and decrement values.

    Seen in 1 report
  20. A swallowed quote error left the funding value null, removing the estimate hedge and disabling the affordability guard.

    Seen in 1 report
  21. A swap in the flash loan liquidation function had no minimum receive parameter unlike similar functions.

    Seen in 1 report
  22. A ternary picks the larger of the adjusted cap and the DAO target instead of the smaller, and the result is never enforced.

    Seen in 1 report
  23. A ternary uses reward minus balance instead of balance when the pool holds less than the reward.

    Seen in 1 report
  24. A testing value of 60 days was left as the stale price threshold instead of the intended 30 days.

    Seen in 1 report
  25. A tier's beneficiary was not stored when it matched the current default, relying on a fallback that later changed.

    Seen in 1 report
  26. A time duration was passed as the number of snapshots to the EMA function.

    Seen in 1 report
  27. A timestamp in seconds is subtracted from a week count and compared to 2, mixing units.

    Seen in 1 report
  28. A token amount was added directly to a USD value without conversion.

    Seen in 1 report
  29. A token transfer was made without checking the amount was greater than zero, so tokens that revert on zero transfers blocked the claim.

    Seen in 1 report
  30. A total was cast from a wider to a narrower unsigned integer without checking the maximum value.

    Seen in 1 report
  31. A transcription error when copying the boost table into the contract leaves one entry different from the documented value.

    Seen in 1 report
  32. A transfer library that does not check the token address has code is used instead of one that does.

    Seen in 1 report
  33. A try/catch swallows the callback revert when paused, so funds move without updating the accounting.

    Seen in 1 report
  34. A typo where a subtraction expression was written instead of an assignment meant the computed adjusted long amount was discarded and the variable kept its default zero value.

    Seen in 1 report
  35. A typo where the assignment operator was replaced by the equality operator, so the status field is compared rather than updated.

    Seen in 1 report
  36. A typographical error used a non-existent proposal type instead of the grant type, changing quorum logic.

    Seen in 1 report
  37. A typographical error uses the wrong variable when fetching the exchange rate inside the quote loop.

    Seen in 1 report
  38. A uint32 parameter was compared against a value scaled by 1e18, so ordinary values overflowed the type.

    Seen in 1 report
  39. A user-controlled value is used as a proxy for whether finalisation occurred instead of a dedicated state variable.

    Seen in 1 report
  40. A user-supplied mail_from value was passed to the mail library without checking it belonged to the user or the site.

    Seen in 1 report
  41. A user-supplied strategy identifier was trusted for the LTV check without confirming it matched the user's actual strategy.

    Seen in 1 report
  42. A variable mix-up passes the old borrowing key where the newly generated key was intended.

    Seen in 1 report
  43. A variable was used in the fee calculation before assignment, defaulting to zero.

    Seen in 1 report
  44. A very short bidding window combined with cheap block space lets one bidder exclude all other bidders.

    Seen in 1 report
  45. A wad multiplication function was used on a value that was not in wad format, causing an unintended division.

    Seen in 1 report
  46. A wall-clock timestamp is converted to a monotonic clock value using saturating subtraction, which floors to zero after a restart.

    Seen in 1 report
  47. A wide gap between high and low price bounds in a lookup table entry makes the iterative reserve calculation overshoot and never converge.

    Seen in 1 report
  48. A withdrawal calculation could go below zero and cast to an unsigned zero, avoiding streaming tokens while earning rewards.

    Seen in 1 report
  49. A zero previous survival is replaced with one at the weight limit, so later increments are no longer scaled down.

    Seen in 1 report
  50. A zero withdrawable amount is treated as a special case returning the asset unit instead of zero.

    Seen in 1 report