Skip to content

Static analysis

fact forge lint runs with the exclusion list in foundry.toml. Each excluded lint is documented with a reason (for example block-timestamp is excluded because the protocol’s logic is defined in terms of timestamps by design, and calls-loop because the upkeep loops in NoteAutomation.checkUpkeep are bounded by maxSeriesPerCheck and the number of templates, and Treasury/Desk asset loops by governance-set lists).

fact Slither, Aderyn and forge lint outputs from the internal security review are committed under audit/static-analysis/ and audit/sale/ with dated file names, and triaged in audit/static-analysis.md (0 true positives at the reviewed commit; every accepted pattern is listed with its reason).

planned The following are part of the specified CI pipeline and will be enabled as the repository matures:

ToolScopePolicy
SlitherAll of src/High and medium findings fail CI unless triaged with an inline justification
AderynAll of src/Report attached to each release
forge build --sizesContract sizesFail if any contract exceeds 24 KiB
forge fmt --checkFormattingFail on diff
forge coverageCoverageFail below 95% on non-mock sources
PatternWhereReason
Reentrancy via ERC-1155 hookNoteLegs → NoteCore.onLegTransferRequired for coupon accounting on transfer; guarded and unit-tested
Timestamp comparisonsNoteCore, OracleAdapter, Treasury, sNOTEProtocol semantics are calendar-based
Unbounded loop over assetListTreasury.reserveValueQuoteAsset list is governance-controlled and small; documented gas bound
Division before multiplicationFixedPointMath WAD helpersUses mulDiv with explicit rounding direction

Static analysis reports for tagged releases will be published in the repository under contracts/reports/. Nothing has been published yet.