Skip to content

fix(contracts): security audit pass — High + Medium findings - #777

Merged
thiras merged 4 commits into
mainfrom
security/fix-audit-findings
Jun 1, 2026
Merged

thiras merged 4 commits into
mainfrom
security/fix-audit-findings

Conversation

@thiras

@thiras thiras commented Jun 1, 2026

Copy link
Copy Markdown
Contributor

Summary

A six-domain security scan of decdn/contracts (corroborated by aderyn 0-High and slither Low/Info-only) surfaced 4 High, ~11 Medium, plus Lows/Info and ADR-026 doc-drift. This PR fixes High + Medium + doc-drift, in one commit per domain. Deliberate design-postures and the governance/crypto domain are intentionally untouched; large deferred ADR-031 features remain deferred (issues filed).

What's fixed

Payment/fee (d7ddcf3)

  • M-3: PaymentChannel._route resets the USDC allowance to 0 after settlement; setFeeRouter zeroes the outgoing router's allowance.
  • M-2: openChannel/topUp credit the measured balance delta (fee-on-transfer hardening).
  • topUp gated whenNotPaused; FeeRouter window-views clamp n to the governable ceiling.
  • H-3: BuybackBurner rejects minOut == 0, bounds amountIn by balance, adds rescueUSDC, documents mandatory _performSwap subclass invariants.
  • Doc-drift: three-bucket 60/30/10 NatSpec per ADR 026.

Slashing (d947dec)

  • H-1: unified slash-path pause accumulator — CapacityBond.pausedTotal is now the single combined counter (SlashAppeal credits its pause time via creditPauseTime), so a pause on SlashAppeal alone can no longer run out the filing window and let a slash finalize against an operator who couldn't appeal.
  • M-3: governance forceResolveStuckAppeal escape hatch for a role-revocation-wedged escrow.
  • M-2: upholdAppeal degrades the pool leg to a burn if the transfer fails.

Blacklist/origin (2626f71)

  • H-2: _addHash reverts while an appeal is live (was silently orphaning the appeal + resetting the slash boundary).
  • M-1: per-region concurrent cap counts only fast-tracked appeals (un-acted Open filings no longer saturate a region).
  • M-4: addOperator is nonReentrant.
  • M-2: OriginAssignment activation/prune consult both the origin and operator blacklist mappings.

Static-analysis hygiene (bfdcccf): annotate the new trusted-staticcall / derived-delta-equality false positives.

Deferred (tracked separately, not in this PR)

  • CapacityBond setUnbondingPeriod ↔ maxEvidenceAgeUs mirror: CapacityBond is at the EIP-170 ceiling (124 B headroom); a role-gated SlashJudge-ref setter overflows it by ~290 B. SlashJudge still enforces the other half of the invariant.
  • ADR-031 deferred features (rejection cooldown, token-holder standing enforcement, perjury denylist) — large, ADR-scoped.
  • Deliberate postures left as-is per scoping: PaymentChannel settlement-pause posture, DecdnGovernor bootstrap quorum floor, CapacityBond min-bond grace, removeOperator un-eject.

Verification

  • forge fmt --check ✅
  • FOUNDRY_PROFILE=ci forge build --sizes --deny warnings ✅ (CapacityBond 24,452 / 24,576)
  • forge test ✅ 476 passed
  • aderyn ✅ 0 High
  • slither ✅ exit 0 (fail-on medium)

New focused tests cover every fix: pause-coupling filing-window extension, force-resolve after role revocation, _addHash guard, region-cap-on-fasttrack, BuybackBurner guards + rescue, allowance reset, FeeRouter clamp, operator-mapping blacklist prune.

🤖 Generated with Claude Code

thiras and others added 4 commits June 2, 2026 01:59
Address audit findings in the payment/fee domain:

- PaymentChannel `_route`: reset USDC allowance to 0 after `routeSettlement`
  so an under-pulling or re-pointed router keeps no standing allowance (M-3);
  `setFeeRouter` zeroes the outgoing router's allowance on re-point.
- PaymentChannel `openChannel`/`topUp`: credit the measured balance delta
  rather than the requested amount, hardening against a future fee-on-transfer
  USDC proxy upgrade that would otherwise over-credit the shared pool (M-2).
- PaymentChannel `topUp`: gate with `whenNotPaused` — refuse new inflows during
  an incident while exit paths stay open (safe hardening).
- FeeRouter `bytesInWindow`/`totalBytesInWindow`: clamp caller-supplied `n` to
  WINDOW_EPOCHS_CEILING so no on-chain caller can force an unbounded loop.
- BuybackBurner: reject `minOut == 0`, bound `amountIn` by the USDC balance,
  add governance-gated `rescueUSDC`, and document mandatory TWAP/approval
  invariants for the `_performSwap` subclass (H-3).
- Docs: correct stale four-bucket / 60-25-10-5 NatSpec to three-bucket
  60/30/10 per ADR 026 (IFeeRouter, BuybackBurner).

Tests: allowance-reset under under-pull, topUp-while-paused, FeeRouter window
clamp, BuybackBurner minOut/amountIn guards + rescueUSDC. All 469 pass.

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
Address audit findings in the slashing domain:

- H-1 unified pause accumulator: `CapacityBond.pausedTotal` is now the single
  combined counter for the slash path. `SlashAppeal._unpause` credits its pause
  time to it via the new `creditPauseTime` (SLASH_APPEAL_ROLE), and SlashAppeal's
  review/ratification windows read it. Previously a pause on SlashAppeal alone
  did NOT extend the CapacityBond filing window, so a paused appeal could be
  raced to finality against an operator who was blocked from filing (ADR 028 §5).
- M-3 escrow escape hatch: add governance-gated `forceResolveStuckAppeal`, which
  resolves an `AppealOpen` record on the upheld path (50/50) when SLASH_APPEAL_ROLE
  was revoked mid-migration and wedged the escrow with no caller able to settle.
- M-2 uphold pool fallback: `upholdAppeal` degrades the challenger-pool leg to a
  burn if the transfer fails, so a reverting/blocklisting pool cannot block the
  uphold and let `cleanupExpiredAppeal` flip it to an operator-favorable grant.

Deferred (CapacityBond is at 124 B of EIP-170 headroom; a role-gated setter +
getter for the SlashJudge ref overflows it by ~290 B): the `setUnbondingPeriod`
mirror of the `maxEvidenceAgeUs < unbondingPeriod` invariant. Tracked as a
follow-up — see issue. SlashJudge still enforces the other half of the invariant.

Tests: SlashAppeal-pause extends the CapacityBond filing window; force-resolve
after role revocation distributes 50/50 and reverts when not AppealOpen / not
governance. All 473 pass.

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
Address audit findings in the blacklist/origin domain:

- H-2 `_addHash` live-appeal guard: re-adding a hash now reverts
  (`HashHasActiveAppeal`) while an appeal is live, instead of silently clearing
  `suspended` and refreshing `addedAt` — which orphaned the in-flight appeal and
  reset the slash-eligibility boundary. Governance must terminate the appeal
  (reject/reverse/ratify) before re-adding.
- M-1 region cap counts only fast-tracked appeals: the per-region concurrent cap
  is now charged at `fastTrackBlacklistAppeal` (interim relief) rather than at
  open, so un-acted-upon Open filings can no longer saturate a region's budget.
  The decrement moves to the fast-tracked termination paths accordingly.
- M-4 `addOperator` is now `nonReentrant` (it makes an external `ejectNode`
  call), consistent with the appeal mutators.
- M-2 origin↔operator blacklist: `OriginAssignment.activateAssignment` and
  `pruneBlacklistedAssignment` now consult BOTH `isOriginBlacklisted` and
  `isOperatorBlacklisted`, so an operator blacklisted via either mapping is
  rejected at activation and prunable (no stale authorization).

Tests: re-add reverts while appeal active (and is allowed again after
termination); cap counts fast-tracked not Open; activate/prune handle the
operator mapping. All 476 pass.

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
The balance-delta deposit accounting (PaymentChannel) and the cross-contract
pause-time read (SlashAppeal) introduce trusted-token / trusted-contract
staticcalls under `nonReentrant`, plus a `received == 0` presence check on a
derived balance delta. These trip aderyn `reentrancy-state-change` and slither
`incorrect-equality`, both false positives here. Annotate them to keep the
CI static-analysis gates (aderyn fail-on-high, slither fail-on-medium) green,
matching the existing suppression convention in these files.
@github-actions

github-actions Bot commented Jun 1, 2026

Copy link
Copy Markdown

Contracts coverage

Line coverage: 88.27% (1783/2020 lines)
▲ +0.51pp vs base (87.76% → 88.27%)
Run: 26788065308

@github-actions

github-actions Bot commented Jun 1, 2026

Copy link
Copy Markdown

Gas snapshot

Gas changes vs base
No files changed, compilation skipped

Ran 24 tests for test/BuybackBurner.t.sol:BuybackBurnerTest
[PASS] test_constructor_grantsAdminAndGovernanceRoles() (gas: 14873)
[PASS] test_constructor_revertsOnZeroAdmin() (gas: 67989)
[PASS] test_constructor_revertsOnZeroToken() (gas: 67964)
[PASS] test_constructor_revertsOnZeroUsdc() (gas: 67972)
[PASS] test_executeBuyback_happyPath_burnsAndEmits() (gas: 110748)
[PASS] test_executeBuyback_revertsPoolNotWiredWhenPoolUnset() (gas: 973169)
[PASS] test_executeBuyback_revertsPoolNotWiredWhenVaultUnset() (gas: 973299)
[PASS] test_executeBuyback_revertsSwapNotImplementedWhenActualDeltaIsZero() (gas: 65569)
[PASS] test_executeBuyback_revertsSwapReportMismatch() (gas: 116470)
[PASS] test_executeBuyback_revertsWhenAmountExceedsBalance() (gas: 77138)
[PASS] test_executeBuyback_revertsWhenPaused() (gas: 73161)
[PASS] test_executeBuyback_revertsWithoutKeeperRole() (gas: 64237)
[PASS] test_executeBuyback_revertsZeroAmount() (gas: 20661)
[PASS] test_executeBuyback_revertsZeroMinOut() (gas: 65728)
[PASS] test_pause_revertsWithoutPauserRole() (gas: 11929)
[PASS] test_rescueUSDC_revertsOnZeroAmount() (gas: 13609)
[PASS] test_rescueUSDC_revertsOnZeroRecipient() (gas: 13609)
[PASS] test_rescueUSDC_revertsWithoutGovernanceRole() (gas: 12259)
[PASS] test_rescueUSDC_transfersToRecipient() (gas: 56391)
[PASS] test_setPool_emitsUpdateEvent() (gas: 24938)
[PASS] test_setPool_revertsWithoutGovernanceRole() (gas: 12273)
[PASS] test_setVault_emitsUpdateEvent() (gas: 24925)
[PASS] test_setVault_revertsWithoutGovernanceRole() (gas: 12129)
[PASS] test_unpause_revertsWithoutPauserRole() (gas: 23910)
Suite result: ok. 24 passed; 0 failed; 0 skipped; finished in 10.85ms (9.79ms CPU time)

Ran 54 tests for test/GovernanceLifecycle.t.sol:GovernanceLifecycleTest
[PASS] test_canary_executorIsTimelock() (gas: 9969)
[PASS] test_canary_governanceRoleHandoff() (gas: 99144)
[PASS] test_canary_governorVoteWeightWired() (gas: 129967)
[PASS] test_lifecycle_CapacityBond_setClaimSlashGateEpochs_happy() (gas: 589504)
[PASS] test_lifecycle_CapacityBond_setClaimSlashGateEpochs_outOfBounds() (gas: 595197)
[PASS] test_lifecycle_CapacityBond_setMaxCapacityMbps_happy() (gas: 589226)
[PASS] test_lifecycle_CapacityBond_setMaxCapacityMbps_outOfBounds() (gas: 595130)
[PASS] test_lifecycle_CapacityBond_setMaxMultiaddrSize_happy() (gas: 589246)
[PASS] test_lifecycle_CapacityBond_setMaxMultiaddrSize_outOfBounds() (gas: 595221)
[PASS] test_lifecycle_CapacityBond_setMinBond_happy() (gas: 589380)
[PASS] test_lifecycle_CapacityBond_setMinBond_outOfBounds() (gas: 595175)
[PASS] test_lifecycle_CapacityBond_setMinCapacityMbps_happy() (gas: 589355)
[PASS] test_lifecycle_CapacityBond_setMinCapacityMbps_outOfBounds() (gas: 595152)
[PASS] test_lifecycle_CapacityBond_setMultiaddrUpdateCooldown_happy() (gas: 606409)
[PASS] test_lifecycle_CapacityBond_setMultiaddrUpdateCooldown_outOfBounds() (gas: 595082)
[PASS] test_lifecycle_CapacityBond_setRegionStabilityWindow_happy() (gas: 589294)
[PASS] test_lifecycle_CapacityBond_setRegionStabilityWindow_outOfBounds() (gas: 595154)
[PASS] test_lifecycle_CapacityBond_setTreasury_happy() (gas: 606765)
[PASS] test_lifecycle_CapacityBond_setUnbondingPeriod_happy() (gas: 589296)
[PASS] test_lifecycle_CapacityBond_setUnbondingPeriod_outOfBounds() (gas: 595158)
[PASS] test_lifecycle_ContentBlacklist_addHashGlobal_happy() (gas: 611922)
[PASS] test_lifecycle_ContentBlacklist_addHashGlobal_outOfBounds() (gas: 597246)
[PASS] test_lifecycle_ContentBlacklist_addOperator_happy() (gas: 640678)
[PASS] test_lifecycle_ContentBlacklist_addOperator_outOfBounds() (gas: 602436)
[PASS] test_lifecycle_ContentBlacklist_registerRegionalBody_happy() (gas: 611166)
[PASS] test_lifecycle_ContentBlacklist_removeHashGlobal_happy() (gas: 997238)
[PASS] test_lifecycle_ContentBlacklist_removeHashGlobal_outOfBounds() (gas: 599794)
[PASS] test_lifecycle_ContentBlacklist_removeOperator_happy() (gas: 1025729)
[PASS] test_lifecycle_ContentBlacklist_setAppealBond_happy() (gas: 591735)
[PASS] test_lifecycle_ContentBlacklist_setAppealBond_outOfBounds() (gas: 597567)
[PASS] test_lifecycle_ContentBlacklist_setOriginBlacklist_happy() (gas: 610300)
[PASS] test_lifecycle_ContentBlacklist_setOriginBlacklist_outOfBounds() (gas: 598088)
[PASS] test_lifecycle_DecdnGovernor_setAgeRampMonths_happy() (gas: 631070)
[PASS] test_lifecycle_DecdnGovernor_setAgeRampMonths_outOfBounds() (gas: 636788)
[PASS] test_lifecycle_DecdnGovernor_setVoteCapBps_happy() (gas: 631077)
[PASS] test_lifecycle_DecdnGovernor_setVoteCapBps_outOfBounds() (gas: 636830)
[PASS] test_lifecycle_FeeRouter_setBuybackBurner_happy() (gas: 589629)
[PASS] test_lifecycle_FeeRouter_setBuybackBurner_outOfBounds() (gas: 597158)
[PASS] test_lifecycle_FeeRouter_setSharesAndDestinations_happy() (gas: 622563)
[PASS] test_lifecycle_FeeRouter_setSharesAndDestinations_outOfBounds() (gas: 598254)
[PASS] test_lifecycle_FeeRouter_setShares_happy() (gas: 608708)
[PASS] test_lifecycle_FeeRouter_setShares_outOfBounds() (gas: 597051)
[PASS] test_lifecycle_FeeRouter_setTreasury_happy() (gas: 589655)
[PASS] test_lifecycle_FeeRouter_setTreasury_outOfBounds() (gas: 594903)
[PASS] test_lifecycle_FeeRouter_setWindowEpochs_happy() (gas: 611399)
[PASS] test_lifecycle_FeeRouter_setWindowEpochs_outOfBounds() (gas: 597427)
[PASS] test_lifecycle_PublisherRegistry_setMaxNamespacesPerPublisher_happy() (gas: 591962)
[PASS] test_lifecycle_PublisherRegistry_setMaxNamespacesPerPublisher_outOfBounds() (gas: 597562)
[PASS] test_lifecycle_PublisherRegistry_setNamespaceTransferTimelock_happy() (gas: 591878)
[PASS] test_lifecycle_PublisherRegistry_setNamespaceTransferTimelock_outOfBounds() (gas: 597604)
[PASS] test_lifecycle_SlashAppeal_setAppealBond_happy() (gas: 591652)
[PASS] test_lifecycle_SlashAppeal_setAppealBond_outOfBounds() (gas: 597519)
[PASS] test_lifecycle_SlashAppeal_setChallengerIncentivePool_happy() (gas: 592113)
[PASS] test_lifecycle_SlashAppeal_setChallengerIncentivePool_outOfBounds() (gas: 597393)
Suite result: ok. 54 passed; 0 failed; 0 skipped; finished in 135.39ms (108.98ms CPU time)

Ran 3 tests for test/InterfaceFreeze.t.sol:InterfaceFreezeTest
[PASS] test_originAssignment_abiFrozen() (gas: 1298)
[PASS] test_paymentChannel_abiFrozen() (gas: 1540)
[PASS] test_slashJudge_abiFrozen() (gas: 870)
Suite result: ok. 3 passed; 0 failed; 0 skipped; finished in 453.64µs (80.50µs CPU time)

Ran 30 tests for test/OriginAssignment.t.sol:OriginAssignmentTest
[PASS] test_activate_blacklistSkippedWhenUnset() (gas: 2047543)
[PASS] test_activate_onlyGovernance() (gas: 140585)
[PASS] test_activate_replacesPreviousSet() (gas: 352112)
[PASS] test_activate_revertsBeforeTimelock() (gas: 140524)
[PASS] test_activate_revertsNoPending() (gas: 21009)
[PASS] test_activate_revertsOperatorBlacklisted() (gas: 173841)
[PASS] test_activate_revertsOperatorBlacklistedViaOperatorMapping() (gas: 183923)
[PASS] test_activate_revertsOperatorWentInactive() (gas: 155953)
[PASS] test_activate_setsAuthorizedSet() (gas: 224900)
[PASS] test_cancel_clearsPending() (gas: 110536)
[PASS] test_defaultOpen_addAndRemove() (gas: 78409)
[PASS] test_defaultOpen_onlyGovernance() (gas: 21169)
[PASS] test_defaultOpen_revertsInactive() (gas: 27910)
[PASS] test_defaultOpen_setAllowlist() (gas: 172108)
[PASS] test_propose_overwriteReplacesPending() (gas: 128731)
[PASS] test_propose_revertsDuplicate() (gas: 34918)
[PASS] test_propose_revertsEmpty() (gas: 21925)
[PASS] test_propose_revertsInactiveOperator() (gas: 39841)
[PASS] test_propose_revertsNonOwner() (gas: 27271)
[PASS] test_propose_revertsTooMany() (gas: 39410)
[PASS] test_propose_storesPending() (gas: 133692)
[PASS] test_prune_removesBlacklistedOperator() (gas: 248023)
[PASS] test_prune_removesOperatorBlacklistedViaOperatorMapping() (gas: 248717)
[PASS] test_prune_revertsWhenBlacklistUnset() (gas: 1865198)
[PASS] test_prune_revertsWhenNotBlacklisted() (gas: 226404)
[PASS] test_revoke_byPublisherAndGovernance() (gas: 237252)
[PASS] test_revoke_revertsNonMember() (gas: 23619)
[PASS] test_setAssignmentTimelock_enforcesBounds() (gas: 24759)
[PASS] test_setContentBlacklist_rejectsZero() (gas: 13473)
[PASS] test_setMaxOrigins_enforcesBounds() (gas: 13857)
Suite result: ok. 30 passed; 0 failed; 0 skipped; finished in 11.16ms (10.48ms CPU time)

Ran 89 tests for test/CapacityBond.t.sol:CapacityBondTest
[PASS] testFuzz_bondRequired_monotonic(uint256,uint256) (runs: 1024, μ: 19318, ~: 19622)
[PASS] test_appealGrant_unlocksClaimBeforeGateExpiry() (gas: 433670)
[PASS] test_bondRequired_matchesAdrWorkedExamples() (gas: 29776)
[PASS] test_bondRequired_strictlyMonotonic() (gas: 37730)
[PASS] test_bondRequired_zeroForZeroMbps() (gas: 13183)
[PASS] test_capacityBand_defaults() (gas: 10600)
[PASS] test_capacityBand_floorAlwaysBelowCeiling() (gas: 29319)
[PASS] test_claimVestedCredit_movesIntoActiveBond() (gas: 214461)
[PASS] test_claimVestedCredit_multiClaimFollowsLinearCurve() (gas: 219024)
[PASS] test_claimVestedCredit_multiSlash_gatedByOlderStandingSlash() (gas: 584110)
[PASS] test_claimVestedCredit_revertsWhenNoActiveBond() (gas: 144484)
[PASS] test_claimVestedCredit_revertsWhenSlashedInWindow() (gas: 438976)
[PASS] test_claimVestedCredit_succeedsAfterSlashGateExpires() (gas: 442008)
[PASS] test_creditSlash_escrowsThenDistributes5050AtFinality() (gas: 458250)
[PASS] test_curveDefaults() (gas: 10646)
[PASS] test_declareMbps_acceptsFloorAndCeiling() (gas: 161199)
[PASS] test_declareMbps_emitsOldAndNewValue() (gas: 158302)
[PASS] test_declareMbps_revertsAboveCeiling() (gas: 18062)
[PASS] test_declareMbps_revertsBelowFloor() (gas: 17995)
[PASS] test_declareMbps_revertsWhenBondBelowCurve() (gas: 131850)
[PASS] test_declareMbps_revertsZero() (gas: 17940)
[PASS] test_declareMbps_succeedsExactlyAtCurve() (gas: 147236)
[PASS] test_declaredMbps_storesValue() (gas: 147258)
[PASS] test_escrowHooks_requireSlashAppealRole() (gas: 17039)
[PASS] test_finalizeUnappealedSlash_distributes5050() (gas: 356698)
[PASS] test_firstBondedAt_immutableAcrossReBonds() (gas: 111491)
[PASS] test_firstBondedAt_setsOnFirstBond() (gas: 102557)
[PASS] test_forfeitUnvestedCredit_burnsWhenNoTreasury() (gas: 256084)
[PASS] test_forfeitUnvestedCredit_doesNotClawBackVestedUnclaimed() (gas: 291625)
[PASS] test_forfeitUnvestedCredit_onUnbond() (gas: 300423)
[PASS] test_genesisCredit_fullVestAfterDuration() (gas: 141195)
[PASS] test_genesisCredit_grantWithinWindow() (gas: 139153)
[PASS] test_genesisCredit_revertsAfterWindow() (gas: 82784)
[PASS] test_genesisCredit_vestsLinearly() (gas: 141475)
[PASS] test_markAppealOpen_blocksFinalize() (gas: 327325)
[PASS] test_pause_revertsWithoutRole() (gas: 14704)
[PASS] test_pendingCreditSlash_reducesOriginalGrant() (gas: 433104)
[PASS] test_reduceBondAtTier_activeOnly() (gas: 899)
[PASS] test_reduceBondAtTier_remainderClip() (gas: 1101)
[PASS] test_reduceBondAtTier_slashEqualsActive() (gas: 942)
[PASS] test_reduceBondAtTier_spillsIntoUnbonding() (gas: 932)
[PASS] test_reduceBondAtTier_unbondingOnly() (gas: 951)
[PASS] test_reduceBondAtTier_zeroInputs() (gas: 1471)
[PASS] test_registerNode_revertsOnInvalidEd25519Sig() (gas: 179153)
[PASS] test_registerNode_revertsWhenAlreadyActive() (gas: 387843)
[PASS] test_registerNode_revertsWhenBondBelowCurve() (gas: 207561)
[PASS] test_registerNode_succeedsAtCurve() (gas: 415491)
[PASS] test_requestUnbond_allowedWhenNoCapacityDeclared() (gas: 164080)
[PASS] test_requestUnbond_revertsWhenItDropsBelowCurve() (gas: 160394)
[PASS] test_requestUnbond_succeedsDownToExactlyCurve() (gas: 208876)
[PASS] test_setAlpha_revertsOutOfBounds() (gas: 18430)
[PASS] test_setAlpha_revertsWhenGbpsTierOutOfRange() (gas: 29865)
[PASS] test_setAlpha_updatesCurveAndEmits() (gas: 33866)
[PASS] test_setCapacity_onlyGovernance() (gas: 19701)
[PASS] test_setClaimSlashGateEpochs_revertsWithoutRole() (gas: 14846)
[PASS] test_setCurve_onlyGovernance() (gas: 19460)
[PASS] test_setKAlpha_orderingMatters() (gas: 56090)
[PASS] test_setK_revertsWhenGbpsTierOutOfRange() (gas: 43990)
[PASS] test_setK_updatesCurveAndEmits() (gas: 35649)
[PASS] test_setMaxCapacity_acceptsInclusiveBounds() (gas: 24451)
[PASS] test_setMaxCapacity_revertsOutOfBounds() (gas: 18373)
[PASS] test_setMaxCapacity_updatesBandAndEmits() (gas: 31107)
[PASS] test_setMaxMultiaddrSize_revertsWithoutRole() (gas: 14999)
[PASS] test_setMinBond_revertsWithoutRole() (gas: 14890)
[PASS] test_setMinCapacity_acceptsInclusiveBounds() (gas: 24688)
[PASS] test_setMinCapacity_revertsOutOfBounds() (gas: 18581)
[PASS] test_setMinCapacity_updatesBandAndEmits() (gas: 167005)
[PASS] test_setMultiaddrUpdateCooldown_revertsWithoutRole() (gas: 14844)
[PASS] test_setRegionStabilityWindow_revertsWithoutRole() (gas: 14889)
[PASS] test_setTreasury_revertsWithoutRole() (gas: 14963)
[PASS] test_setUnbondingPeriod_revertsWithoutRole() (gas: 14935)
[PASS] test_settleAppealGranted_clearsAndRefunds() (gas: 303532)
[PASS] test_settleAppealGranted_multiSlash_recomputesThenClears() (gas: 429148)
[PASS] test_settleAppealGranted_reverseMiddleSlash_keepsNewest() (gas: 578178)
[PASS] test_settleAppealUpheld_distributes5050() (gas: 348782)
[PASS] test_slashHitsVestedAndUnvestedTogether() (gas: 476143)
[PASS] test_slashHitsVestedButUnclaimed() (gas: 443570)
[PASS] test_slashId_persistsRecord() (gas: 314901)
[PASS] test_slash_creditSlash_escalatesAcrossTiers() (gas: 666622)
[PASS] test_slash_doesNotEnforceCurve() (gas: 362563)
[PASS] test_slash_escrowsWithoutDistribution() (gas: 326191)
[PASS] test_slash_stampsSlashedAtEpoch() (gas: 314686)
[PASS] test_slash_tier3_mixedBond_exhaustsActiveTapsUnbonding() (gas: 599462)
[PASS] test_slash_tierEscalation_15then50pct() (gas: 547261)
[PASS] test_slashedAtEpoch_zeroBeforeSlash() (gas: 10152)
[PASS] test_unpause_revertsWithoutRole() (gas: 94524)
[PASS] test_updateMultiaddrs_revertsWhenNodeNotActive() (gas: 15613)
[PASS] test_updateRegion_cooldownAndPrevSnapshot() (gas: 458001)
[PASS] test_updateRegion_revertsWhenNodeNotActive() (gas: 15741)
Suite result: ok. 89 passed; 0 failed; 0 skipped; finished in 148.09ms (141.31ms CPU time)

Ran 19 tests for test/ContentBlacklist.t.sol:ContentBlacklistTest
[PASS] test_addHashGlobal_andQuery() (gas: 40454)
[PASS] test_addHashGlobal_revertsWithoutGovernanceRole() (gas: 14608)
[PASS] test_addHashRegional_globalTakesPrecedence() (gas: 44310)
[PASS] test_addHashRegional_revertsWithoutRegionalBodyRole() (gas: 14750)
[PASS] test_addHash_revertsWhileAppealActive() (gas: 233813)
[PASS] test_addOperator_callsEjectOnCapacityBond() (gas: 93920)
[PASS] test_fullAppealFlow_ratifyRemovesHash() (gas: 276038)
[PASS] test_hasActiveAppeal_clearedOnLapseOpen() (gas: 223830)
[PASS] test_hasActiveAppeal_clearedOnReject() (gas: 410381)
[PASS] test_hasActiveAppeal_clearedOnReverse() (gas: 255340)
[PASS] test_openBlacklistAppeal_revertsDuplicatePerHash() (gas: 334316)
[PASS] test_openBlacklistAppeal_revertsOnEntryNotBlacklisted() (gas: 18635)
[PASS] test_openBlacklistAppeal_revertsOnZeroRegion() (gas: 16243)
[PASS] test_regionalCap_countsFastTrackedNotOpen() (gas: 894100)
[PASS] test_registerRegionalBody_revertsWithoutGovernanceRole() (gas: 14830)
[PASS] test_rejectAppeal_burnsBond() (gas: 229508)
[PASS] test_removeHashRegional_blocksGlobalRegionEntries() (gas: 46682)
[PASS] test_reverseAppeal_clearsSuspendedAndBurnsBond() (gas: 262037)
[PASS] test_setAppealBond_revertsWithoutGovernanceRole() (gas: 14754)
Suite result: ok. 19 passed; 0 failed; 0 skipped; finished in 3.57ms (2.64ms CPU time)

Ran 13 tests for test/DecdnGovernor.t.sol:DecdnGovernorTest
[PASS] test_ageRampMonthsAt_preservesPriorReadAfterLaterPush() (gas: 4104760)
[PASS] test_getVotes_halfRamp() (gas: 173099)
[PASS] test_getVotes_historicalSnapshotIgnoresFutureSlash() (gas: 221405)
[PASS] test_getVotes_ramp() (gas: 173020)
[PASS] test_getVotes_recoversAfterWindowSlidesPastSlash() (gas: 196808)
[PASS] test_getVotes_uncappedWhenBelowCap() (gas: 173006)
[PASS] test_getVotes_zeroIfNeverBonded() (gas: 93593)
[PASS] test_getVotes_zeroWhenSlashedInWindow() (gas: 119032)
[PASS] test_proposalThreshold_isPointOnePercent() (gas: 71807)
[PASS] test_quorum_isFourPercentOfTotalBytesInWindow() (gas: 71639)
[PASS] test_setAgeRampMonths_revertsWithoutTimelockCaller() (gas: 11013)
[PASS] test_setVoteCapBps_revertsWithoutTimelockCaller() (gas: 11066)
[PASS] test_voteCapBpsAt_preservesPriorReadAfterLaterPush() (gas: 4104884)
Suite result: ok. 13 passed; 0 failed; 0 skipped; finished in 4.94ms (3.77ms CPU time)

Ran 23 tests for test/DeployProtocol.t.sol:DeployProtocolTest
[PASS] test_assertNoBackDoors_revertsWhenHandoffIncomplete() (gas: 24934827)
[PASS] test_assertNoBackDoors_revertsWhenTimelockMissingRole() (gas: 94428)
[PASS] test_crossContractWiring_capacityBondPeerRoles() (gas: 23419)
[PASS] test_crossContractWiring_genesisGrantorIsTimelock() (gas: 17165)
[PASS] test_crossContractWiring_newContractPeerRoles() (gas: 31445)
[PASS] test_crossContractWiring_slashAppealChallengerPool() (gas: 9920)
[PASS] test_deployTargets_revertsOnZeroChallengerIncentivePool() (gas: 2025645)
[PASS] test_deployTargets_revertsOnZeroDeployer() (gas: 580314)
[PASS] test_deployTargets_revertsOnZeroEd25519Verifier() (gas: 2025513)
[PASS] test_deployTargets_revertsOnZeroEmergencyMultisig() (gas: 2025557)
[PASS] test_deployTargets_revertsOnZeroInitialTokenHolder() (gas: 2025645)
[PASS] test_deployTargets_revertsOnZeroUsdc() (gas: 2025451)
[PASS] test_emergencyMultisig_canPauseAndBlockEntrypoint() (gas: 48410)
[PASS] test_feeRouter_launchSharesDormantBuyback() (gas: 16477)
[PASS] test_feeRouter_treasuryIsTimelock() (gas: 10051)
[PASS] test_governor_openExecutor() (gas: 8743)
[PASS] test_governor_timelockBinding() (gas: 25888)
[PASS] test_roleMatrix_deployerHoldsNoRoleAnywhere() (gas: 66946)
[PASS] test_roleMatrix_emergencyMultisigGrants() (gas: 19569)
[PASS] test_roleMatrix_pauserIsEmergencyMultisig() (gas: 45657)
[PASS] test_roleMatrix_timelockHoldsDefaultAdminOnEveryTarget() (gas: 41846)
[PASS] test_roleMatrix_timelockHoldsGovernanceOnEveryTarget() (gas: 41974)
[PASS] test_token_initialHolderHoldsFullSupply() (gas: 13803)
Suite result: ok. 23 passed; 0 failed; 0 skipped; finished in 10.20ms (5.29ms CPU time)

Ran 7 tests for test/DeployProtocolScript.t.sol:DeployProtocolScriptTest
[PASS] test_readConfig_appliesDefaultsForOptionalVars() (gas: 17786)
[PASS] test_readConfig_deployerIsTxOrigin() (gas: 15801)
[PASS] test_run_abortsBeforeBroadcastWhenManifestExists() (gas: 22040)
[PASS] test_run_revertsIfDeployerIsForgeDefaultSender() (gas: 15305)
[PASS] test_writeManifest_overwritesWhenForced() (gas: 110634)
[PASS] test_writeManifest_revertsOnExistingFile() (gas: 32033)
[PASS] test_writeManifest_writesAllAddresses() (gas: 92307)
Suite result: ok. 7 passed; 0 failed; 0 skipped; finished in 6.72ms (7.08ms CPU time)

Ran 3 tests for test/E2EProtocol.t.sol:E2EProtocolTest
[PASS] test_deployWiring_newContractsWiredAndHandedOff() (gas: 66882)
[PASS] test_e2e_blacklistEjectsOperator() (gas: 420295)
[PASS] test_e2e_registerSettleSlashEjectAppeal() (gas: 1474331)
Suite result: ok. 3 passed; 0 failed; 0 skipped; finished in 7.92ms (2.65ms CPU time)

Ran 12 tests for test/Ed25519Verifier.t.sol:Ed25519VerifierTest
[PASS] test_MalleatedScalarRejected() (gas: 525477)
[PASS] test_NonCanonicalYRejected() (gas: 11387)
[PASS] test_OffCurvePubKeyRejected() (gas: 14174)
[PASS] test_SmallOrderPubKeyRejected() (gas: 40661)
[PASS] test_SmallOrderRRejected() (gas: 39201)
[PASS] test_ValidVectorsAccepted() (gas: 3003445)
[PASS] test_VerifyRunsUnderStaticcall() (gas: 508245)
[PASS] test_WrongLengthSignatureRejected() (gas: 12156)
[PASS] test_WrongMessageRejected() (gas: 507932)
[PASS] test_WrongPubKeyRejected() (gas: 509119)
[PASS] test_WrongRRejected() (gas: 503763)
[PASS] test_WrongSRejected() (gas: 508960)
Suite result: ok. 12 passed; 0 failed; 0 skipped; finished in 77.88ms (77.51ms CPU time)

Ran 17 tests for test/FeeRouter.t.sol:FeeRouterTest
[PASS] test_bytesInWindow_clampsOversizedWindow() (gas: 510226)
[PASS] test_bytesInWindow_sumsTrailingWindow() (gas: 497431)
[PASS] test_bytesInWindow_zeroWindowReturnsZero() (gas: 9387)
[PASS] test_pause_revertsWithoutRole() (gas: 14609)
[PASS] test_routeSettlement_distributesThreeLegs() (gas: 232441)
[PASS] test_routeSettlement_dustRoutesToOperatorWhenBuybackUnset() (gas: 141816)
[PASS] test_routeSettlement_incrementsBytesPerEpoch() (gas: 221502)
[PASS] test_routeSettlement_revertsWithoutRouterRole() (gas: 89186)
[PASS] test_setBuybackBurner_revertsWithoutRole() (gas: 14698)
[PASS] test_setSharesAndDestinations_revertsWithoutRole() (gas: 19547)
[PASS] test_setShares_rejectsNonZeroShareWithoutDestination() (gas: 16217)
[PASS] test_setShares_rejectsSumNot10000() (gas: 14523)
[PASS] test_setShares_revertsWithoutRole() (gas: 15219)
[PASS] test_setTreasury_revertsWithoutRole() (gas: 14763)
[PASS] test_setWindowEpochs_enforcesBounds() (gas: 32758)
[PASS] test_setWindowEpochs_revertsWithoutRole() (gas: 14688)
[PASS] test_unpause_revertsWithoutRole() (gas: 72144)
Suite result: ok. 17 passed; 0 failed; 0 skipped; finished in 4.79ms (3.55ms CPU time)

Ran 27 tests for test/PublisherRegistry.t.sol:PublisherRegistryTest
[PASS] testFuzz_createNamespace_idsAreSequentialAndOwned(uint8) (runs: 1024, μ: 717319, ~: 371835)
[PASS] test_claimContent_multiClaimAcrossNamespaces() (gas: 233820)
[PASS] test_claimContent_recordsClaim() (gas: 134733)
[PASS] test_claimContent_revertsForDefaultOpenNamespace() (gas: 13756)
[PASS] test_claimContent_revertsIfNotOwner() (gas: 66829)
[PASS] test_claimContent_revertsOnDuplicateSameNamespace() (gas: 135319)
[PASS] test_constructor_revertsZeroAdmin() (gas: 36674)
[PASS] test_constructor_setsDefaultsAndRoles() (gas: 19037)
[PASS] test_createNamespace_assignsIdsFromOne() (gas: 92728)
[PASS] test_createNamespace_revertsAtCap() (gas: 98581)
[PASS] test_createNamespace_zeroIsNeverAssigned() (gas: 65471)
[PASS] test_namespaceOf_emptyForUnclaimed() (gas: 8273)
[PASS] test_setMaxNamespaces_revertsOutOfBounds() (gas: 17605)
[PASS] test_setMaxNamespaces_revertsWithoutRole() (gas: 13384)
[PASS] test_setMaxNamespaces_withinBounds() (gas: 20687)
[PASS] test_setTransferTimelock_revertsOutOfBounds() (gas: 17706)
[PASS] test_setTransferTimelock_revertsWithoutRole() (gas: 14763)
[PASS] test_setTransferTimelock_withinBounds() (gas: 20560)
[PASS] test_transfer_cancelByOwner() (gas: 78668)
[PASS] test_transfer_cancelRevertsIfNotOwner() (gas: 93302)
[PASS] test_transfer_finalizeRevertsIfNotPendingOwner() (gas: 93817)
[PASS] test_transfer_finalizeRevertsNoPending() (gas: 68544)
[PASS] test_transfer_fullFlow() (gas: 98658)
[PASS] test_transfer_initiateRevertsIfNotOwner() (gas: 66923)
[PASS] test_transfer_initiateRevertsZeroNewOwner() (gas: 64330)
[PASS] test_transfer_revertsWhenRecipientAtCap() (gas: 150145)
[PASS] test_transfer_selfTransferExemptFromCap() (gas: 95404)
Suite result: ok. 27 passed; 0 failed; 0 skipped; finished in 949.86ms (946.78ms CPU time)

Ran 23 tests for test/SlashAppeal.t.sol:SlashAppealTest
[PASS] test_cleanup_fastTrackedLapse_grantsOperatorFavorable() (gas: 455127)
[PASS] test_cleanup_openLapse_upholds() (gas: 472918)
[PASS] test_fastTrack_requiresMultisig() (gas: 484713)
[PASS] test_forceResolveStuckAppeal_resolvesAfterRoleRevoked() (gas: 521967)
[PASS] test_forceResolveStuckAppeal_revertsWhenNotAppealOpen() (gas: 320040)
[PASS] test_forceResolveStuckAppeal_revertsWithoutGovernanceRole() (gas: 487811)
[PASS] test_frequencyCap_blocksSecondAppealWithinWindow() (gas: 608342)
[PASS] test_grant_newerAppeal_fallsBackToOlderStandingSlash() (gas: 603691)
[PASS] test_grant_olderAppeal_preservesNewerSlashZeroOut() (gas: 603110)
[PASS] test_grant_refundsOperatorAndBondAndClearsZeroOut() (gas: 463283)
[PASS] test_grant_requiresGovernance() (gas: 495318)
[PASS] test_grant_restoresCreditVestingNotLiquid() (gas: 576566)
[PASS] test_grant_revertsIfNotFastTracked() (gas: 486982)
[PASS] test_open_locksEscrowAndPullsBond() (gas: 491027)
[PASS] test_open_revertsAfterFilingWindow() (gas: 481847)
[PASS] test_open_revertsForNonOperator() (gas: 495646)
[PASS] test_open_revertsOnDoubleAppeal() (gas: 486748)
[PASS] test_open_revertsUnknownSlash() (gas: 23755)
[PASS] test_pause_extendsFilingWindow() (gas: 408650)
[PASS] test_reject_burnsBondAndDistributesEscrow() (gas: 478602)
[PASS] test_slashAppealPause_extendsCapacityBondFilingWindow() (gas: 556672)
[PASS] test_uphold_distributesEscrowAndSplitsBond() (gas: 515000)
[PASS] test_uphold_poolUnset_burnsFullBond() (gas: 2249371)
Suite result: ok. 23 passed; 0 failed; 0 skipped; finished in 11.60ms (10.03ms CPU time)

Ran 22 tests for test/SlashJudge.t.sol:SlashJudgeTest
[PASS] test_blacklist_revertsOnHashMismatch() (gas: 68210)
[PASS] test_blacklist_revertsWhenBlacklistedAfterResponse() (gas: 72559)
[PASS] test_blacklist_revertsWhenNotBlacklisted() (gas: 48632)
[PASS] test_blacklist_revertsWhenSuspended() (gas: 72096)
[PASS] test_blacklist_slashesOnProbeResponse() (gas: 189538)
[PASS] test_blacklist_slashesOnStreamResponse() (gas: 190270)
[PASS] test_constructor_revertsWhenEvidenceAgeExceedsUnbonding() (gas: 366864)
[PASS] test_pause_blocksChallenges() (gas: 58348)
[PASS] test_phantom_revertsOnBadProbeSignature() (gas: 46691)
[PASS] test_phantom_revertsOnEvidenceReplay() (gas: 199102)
[PASS] test_phantom_revertsOnFutureEvidence() (gas: 47528)
[PASS] test_phantom_revertsOnNodeIdMismatch() (gas: 37805)
[PASS] test_phantom_revertsOnStaleEvidence() (gas: 49909)
[PASS] test_phantom_revertsOnUnregisteredNode() (gas: 39027)
[PASS] test_phantom_revertsOutsideTimestampWindow() (gas: 49624)
[PASS] test_phantom_revertsWhenStreamOk() (gas: 53546)
[PASS] test_phantom_slashesAndRoundTripsBond() (gas: 179547)
[PASS] test_rate_revertsWhenNotHigher() (gas: 53581)
[PASS] test_rate_slashesWhenStreamRateHigher() (gas: 172123)
[PASS] test_setChallengeBond_enforcesBounds() (gas: 24689)
[PASS] test_setMaxEvidenceAge_enforcesBoundsAndInvariant() (gas: 40199)
[PASS] test_setters_onlyGovernance() (gas: 13759)
Suite result: ok. 22 passed; 0 failed; 0 skipped; finished in 18.16ms (17.04ms CPU time)

Ran 44 tests for test/TestnetFaucet.t.sol:TestnetFaucetTest
[PASS] testFuzz_claim_atOrAboveCooldown(uint256) (runs: 1024, μ: 91485, ~: 91528)
[PASS] testFuzz_claim_belowCooldown(uint256) (runs: 1024, μ: 85185, ~: 85389)
[PASS] test_admin_canGrantAndRevokeRoles() (gas: 56401)
[PASS] test_claim_blocksReentrancy() (gas: 1550228)
[PASS] test_claim_happyPath() (gas: 82821)
[PASS] test_claim_perCallerCooldownIndependence() (gas: 133478)
[PASS] test_claim_revertsBeforeCooldown() (gas: 83092)
[PASS] test_claim_revertsOnInsufficientBalance() (gas: 50715)
[PASS] test_claim_revertsOneSecondBeforeCooldownBoundary() (gas: 82996)
[PASS] test_claim_revertsWhenPaused() (gas: 39998)
[PASS] test_claim_succeedsAfterCooldown() (gas: 90430)
[PASS] test_claim_succeedsAtExactCooldownBoundary() (gas: 87103)
[PASS] test_constructor_allowsZeroCooldown() (gas: 1810378)
[PASS] test_constructor_revertsOnCooldownExceedingMax() (gas: 1015061)
[PASS] test_constructor_revertsOnMainnetChainId() (gas: 988198)
[PASS] test_constructor_revertsOnZeroAdmin() (gas: 985898)
[PASS] test_constructor_revertsOnZeroClaimAmount() (gas: 988045)
[PASS] test_constructor_revertsOnZeroFunding() (gas: 988061)
[PASS] test_constructor_revertsOnZeroGovernance() (gas: 985864)
[PASS] test_constructor_revertsOnZeroPauser() (gas: 985954)
[PASS] test_constructor_revertsOnZeroTokenAddress() (gas: 70468)
[PASS] test_constructor_revertsOnZeroTreasury() (gas: 987830)
[PASS] test_constructor_revertsWhenTreasuryNotApproved() (gas: 1110690)
[PASS] test_constructor_setsStateAndRoles() (gas: 43070)
[PASS] test_nonAdmin_cannotGrantRoles() (gas: 17889)
[PASS] test_pause_blocksClaimUnpauseRestores() (gas: 91691)
[PASS] test_pause_revertsOnNonPauser() (gas: 14607)
[PASS] test_setClaimAmount_revertsOnNonGovernance() (gas: 14702)
[PASS] test_setClaimAmount_revertsOnZero() (gas: 13338)
[PASS] test_setClaimAmount_updatesAndEmits() (gas: 22083)
[PASS] test_setCooldown_acceptsMaxCooldown() (gas: 20228)
[PASS] test_setCooldown_allowsZero() (gas: 94920)
[PASS] test_setCooldown_revertsOnExceedingMax() (gas: 13790)
[PASS] test_setCooldown_revertsOnNonGovernance() (gas: 14705)
[PASS] test_setCooldown_updatesAndEmits() (gas: 22231)
[PASS] test_timeUntilNext_tracksCooldownWindow() (gas: 82615)
[PASS] test_timeUntilNext_zeroBeforeFirstClaim() (gas: 10099)
[PASS] test_unpause_revertsOnNonPauser() (gas: 43483)
[PASS] test_withdraw_revertsOnInsufficientBalance() (gas: 26877)
[PASS] test_withdraw_revertsOnNonGovernance() (gas: 17089)
[PASS] test_withdraw_revertsOnZeroAmount() (gas: 20838)
[PASS] test_withdraw_revertsOnZeroTo() (gas: 18662)
[PASS] test_withdraw_transfersAndEmits() (gas: 44129)
[PASS] test_withdraw_worksWhilePaused() (gas: 68286)
Suite result: ok. 44 passed; 0 failed; 0 skipped; finished in 289.17ms (287.02ms CPU time)

Ran 10 tests for test/Token.t.sol:TokenTest
[PASS] testFuzz_burn_reducesSupplyByExactAmount(uint256) (runs: 1024, μ: 27803, ~: 27700)
[PASS] test_burnFrom_consumesAllowance() (gas: 38534)
[PASS] test_burn_reducesTotalSupplyAndBalance() (gas: 26044)
[PASS] test_constructor_metadata() (gas: 17896)
[PASS] test_constructor_mintsFullSupplyToHolder() (gas: 12954)
[PASS] test_constructor_revertsOnZeroInitialHolder() (gas: 83264)
[PASS] test_constructor_totalSupplyConstantMatches() (gas: 9364)
[PASS] test_noMintFunctionExposed() (gas: 10765)
[PASS] test_noVotesSurfaceExposed() (gas: 11991)
[PASS] test_permit_setsAllowance() (gas: 67380)
Suite result: ok. 10 passed; 0 failed; 0 skipped; finished in 108.59ms (107.96ms CPU time)

Ran 56 tests for test/PaymentChannel.t.sol:PaymentChannelTest
[PASS] testFuzz_settle_refundEqualsDepositMinusClaimed(uint256,uint256) (runs: 1024, μ: 416022, ~: 416090)
[PASS] testFuzz_withdrawThenSettle_partitionsClaim(uint256,uint256,uint256,uint256) (runs: 1024, μ: 554676, ~: 555056)
[PASS] test_close_afterWithdraw_settleRoutesRemainderOnly() (gas: 547394)
[PASS] test_close_atWatermarkNonce_succeeds() (gas: 477450)
[PASS] test_close_revertsAfterExpiry() (gas: 211121)
[PASS] test_close_revertsOnAmountExceedingDeposit() (gas: 223121)
[PASS] test_close_revertsOnByteOnlyAdvance() (gas: 470362)
[PASS] test_close_then_settle_routesAndRefunds() (gas: 426064)
[PASS] test_close_thirdPartyCannotClose() (gas: 213018)
[PASS] test_constructor_revertsOnDisputeWindowOutOfBounds() (gas: 77036)
[PASS] test_constructor_revertsOnEoaFeeRouter() (gas: 77058)
[PASS] test_constructor_revertsOnZeroAdmin() (gas: 71951)
[PASS] test_dispute_higherNonceWins() (gas: 309711)
[PASS] test_dispute_revertsAfterDeadline() (gas: 297276)
[PASS] test_dispute_revertsOnAmountExceedingDeposit() (gas: 305225)
[PASS] test_dispute_revertsOnAmountRegression() (gas: 304835)
[PASS] test_dispute_revertsOnByteOnlyAdvance() (gas: 488772)
[PASS] test_dispute_revertsOnBytesRegression() (gas: 304972)
[PASS] test_dispute_revertsOnStaleNonce() (gas: 302261)
[PASS] test_forcedInclusion_doesNotExtendTwice() (gas: 2916491)
[PASS] test_forcedInclusion_extendsDeadlineOnce() (gas: 2893929)
[PASS] test_forcedInclusion_noExtendWhenAmpleTimeRemains() (gas: 2902445)
[PASS] test_getRateBounds_returnsConfigured() (gas: 9912)
[PASS] test_normalDispute_doesNotExtend() (gas: 319584)
[PASS] test_openChannel_derivesIdAndIncrementsNonce() (gas: 221523)
[PASS] test_openChannel_distinctIdsAcrossProviders() (gas: 351414)
[PASS] test_openChannel_revertsBelowMinDeposit() (gas: 23033)
[PASS] test_openChannel_revertsOnInactiveProvider() (gas: 29784)
[PASS] test_openChannel_revertsWhenPaused() (gas: 47399)
[PASS] test_paused_exitsStillCallable() (gas: 671201)
[PASS] test_reclaimExpired_refundsRemainderToClient() (gas: 452272)
[PASS] test_reclaimExpired_revertsBeforeExpiry() (gas: 206190)
[PASS] test_route_zeroesResidualAllowanceAfterUnderPull() (gas: 535018)
[PASS] test_setDisputeWindow_enforcesBounds() (gas: 24815)
[PASS] test_setFeeRouter_revertsOnEoaRouter() (gas: 18660)
[PASS] test_setFeeRouter_revertsOnZeroAndUnchanged() (gas: 24635)
[PASS] test_setFeeRouter_updatesTarget() (gas: 292460)
[PASS] test_setters_onlyGovernance() (gas: 13998)
[PASS] test_settle_amountEqualsDeposit_zeroRefund() (gas: 410874)
[PASS] test_settle_fullyWithdrawn_noRouterCall() (gas: 473130)
[PASS] test_settle_revertsBeforeDisputeDeadline() (gas: 294513)
[PASS] test_topUp_increasesDeposit() (gas: 226710)
[PASS] test_topUp_onlyClient() (gas: 206621)
[PASS] test_topUp_revertsWhenPaused() (gas: 233022)
[PASS] test_voucher_rejectedOnWrongChannelId() (gas: 339891)
[PASS] test_withdraw_acceptsErc1271Signature() (gas: 717406)
[PASS] test_withdraw_onlyProvider() (gas: 210927)
[PASS] test_withdraw_revertsOnAmountExceedingDeposit() (gas: 222881)
[PASS] test_withdraw_revertsOnBadSignature() (gas: 215715)
[PASS] test_withdraw_revertsOnBytesRegression() (gas: 469281)
[PASS] test_withdraw_revertsOnNonMonotonicNonce() (gas: 468957)
[PASS] test_withdraw_revertsWhenDeltaZero() (gas: 469732)
[PASS] test_withdraw_routesDeltaAndAdvancesWatermark() (gas: 465532)
[PASS] test_withdraw_secondWithdrawRoutesOnlyIncrement() (gas: 554879)
[PASS] test_zeroVoucherClose_disabledAfterWithdraw() (gas: 462930)
[PASS] test_zeroVoucherClose_refundsFullDeposit() (gas: 218313)
Suite result: ok. 56 passed; 0 failed; 0 skipped; finished in 1.75s (1.78s CPU time)

Ran 18 test suites in 1.93s (3.55s CPU time): 476 tests passed, 0 failed, 0 skipped (476 total tests)
━ CapacityBondTest::test_pause_revertsWithoutRole() (gas: 14704 → 14704 | 0 0.000%)
━ CapacityBondTest::test_reduceBondAtTier_activeOnly() (gas: 899 → 899 | 0 0.000%)
━ CapacityBondTest::test_reduceBondAtTier_remainderClip() (gas: 1101 → 1101 | 0 0.000%)
━ CapacityBondTest::test_reduceBondAtTier_slashEqualsActive() (gas: 942 → 942 | 0 0.000%)
━ CapacityBondTest::test_reduceBondAtTier_spillsIntoUnbonding() (gas: 932 → 932 | 0 0.000%)
━ CapacityBondTest::test_reduceBondAtTier_unbondingOnly() (gas: 951 → 951 | 0 0.000%)
━ CapacityBondTest::test_reduceBondAtTier_zeroInputs() (gas: 1471 → 1471 | 0 0.000%)
━ CapacityBondTest::test_registerNode_revertsOnInvalidEd25519Sig() (gas: 179153 → 179153 | 0 0.000%)
━ CapacityBondTest::test_registerNode_revertsWhenAlreadyActive() (gas: 387843 → 387843 | 0 0.000%)
━ CapacityBondTest::test_requestUnbond_allowedWhenNoCapacityDeclared() (gas: 164080 → 164080 | 0 0.000%)
━ CapacityBondTest::test_setAlpha_revertsOutOfBounds() (gas: 18430 → 18430 | 0 0.000%)
━ CapacityBondTest::test_setAlpha_revertsWhenGbpsTierOutOfRange() (gas: 29865 → 29865 | 0 0.000%)
━ CapacityBondTest::test_setMinCapacity_acceptsInclusiveBounds() (gas: 24688 → 24688 | 0 0.000%)
━ CapacityBondTest::test_slashedAtEpoch_zeroBeforeSlash() (gas: 10152 → 10152 | 0 0.000%)
━ CapacityBondTest::test_updateMultiaddrs_revertsWhenNodeNotActive() (gas: 15613 → 15613 | 0 0.000%)
━ CapacityBondTest::test_updateRegion_revertsWhenNodeNotActive() (gas: 15741 → 15741 | 0 0.000%)
━ ContentBlacklistTest::test_addHashGlobal_revertsWithoutGovernanceRole() (gas: 14608 → 14608 | 0 0.000%)
━ ContentBlacklistTest::test_openBlacklistAppeal_revertsOnEntryNotBlacklisted() (gas: 18635 → 18635 | 0 0.000%)
━ ContentBlacklistTest::test_openBlacklistAppeal_revertsOnZeroRegion() (gas: 16243 → 16243 | 0 0.000%)
━ ContentBlacklistTest::test_registerRegionalBody_revertsWithoutGovernanceRole() (gas: 14830 → 14830 | 0 0.000%)
━ ContentBlacklistTest::test_setAppealBond_revertsWithoutGovernanceRole() (gas: 14754 → 14754 | 0 0.000%)
━ DecdnGovernorTest::test_ageRampMonthsAt_preservesPriorReadAfterLaterPush() (gas: 4104760 → 4104760 | 0 0.000%)
━ DecdnGovernorTest::test_getVotes_halfRamp() (gas: 173099 → 173099 | 0 0.000%)
━ DecdnGovernorTest::test_getVotes_historicalSnapshotIgnoresFutureSlash() (gas: 221405 → 221405 | 0 0.000%)
━ DecdnGovernorTest::test_getVotes_ramp() (gas: 173020 → 173020 | 0 0.000%)
━ DecdnGovernorTest::test_getVotes_recoversAfterWindowSlidesPastSlash() (gas: 196808 → 196808 | 0 0.000%)
━ DecdnGovernorTest::test_getVotes_uncappedWhenBelowCap() (gas: 173006 → 173006 | 0 0.000%)
━ DecdnGovernorTest::test_getVotes_zeroIfNeverBonded() (gas: 93593 → 93593 | 0 0.000%)
━ DecdnGovernorTest::test_getVotes_zeroWhenSlashedInWindow() (gas: 119032 → 119032 | 0 0.000%)
━ DecdnGovernorTest::test_proposalThreshold_isPointOnePercent() (gas: 71807 → 71807 | 0 0.000%)
━ DecdnGovernorTest::test_quorum_isFourPercentOfTotalBytesInWindow() (gas: 71639 → 71639 | 0 0.000%)
━ DecdnGovernorTest::test_setAgeRampMonths_revertsWithoutTimelockCaller() (gas: 11013 → 11013 | 0 0.000%)
━ DecdnGovernorTest::test_setVoteCapBps_revertsWithoutTimelockCaller() (gas: 11066 → 11066 | 0 0.000%)
━ DecdnGovernorTest::test_voteCapBpsAt_preservesPriorReadAfterLaterPush() (gas: 4104884 → 4104884 | 0 0.000%)
━ DeployProtocolTest::test_assertNoBackDoors_revertsWhenTimelockMissingRole() (gas: 94428 → 94428 | 0 0.000%)
━ DeployProtocolTest::test_crossContractWiring_capacityBondPeerRoles() (gas: 23419 → 23419 | 0 0.000%)
━ DeployProtocolTest::test_crossContractWiring_newContractPeerRoles() (gas: 31445 → 31445 | 0 0.000%)
━ DeployProtocolTest::test_crossContractWiring_slashAppealChallengerPool() (gas: 9920 → 9920 | 0 0.000%)
━ DeployProtocolTest::test_deployTargets_revertsOnZeroChallengerIncentivePool() (gas: 2025645 → 2025645 | 0 0.000%)
━ DeployProtocolTest::test_deployTargets_revertsOnZeroDeployer() (gas: 580314 → 580314 | 0 0.000%)
━ DeployProtocolTest::test_deployTargets_revertsOnZeroEd25519Verifier() (gas: 2025513 → 2025513 | 0 0.000%)
━ DeployProtocolTest::test_deployTargets_revertsOnZeroEmergencyMultisig() (gas: 2025557 → 2025557 | 0 0.000%)
━ DeployProtocolTest::test_deployTargets_revertsOnZeroInitialTokenHolder() (gas: 2025645 → 2025645 | 0 0.000%)
━ DeployProtocolTest::test_deployTargets_revertsOnZeroUsdc() (gas: 2025451 → 2025451 | 0 0.000%)
━ DeployProtocolTest::test_feeRouter_launchSharesDormantBuyback() (gas: 16477 → 16477 | 0 0.000%)
━ DeployProtocolTest::test_feeRouter_treasuryIsTimelock() (gas: 10051 → 10051 | 0 0.000%)
━ DeployProtocolTest::test_governor_openExecutor() (gas: 8743 → 8743 | 0 0.000%)
━ DeployProtocolTest::test_governor_timelockBinding() (gas: 25888 → 25888 | 0 0.000%)
━ DeployProtocolTest::test_token_initialHolderHoldsFullSupply() (gas: 13803 → 13803 | 0 0.000%)
━ DeployProtocolScriptTest::test_readConfig_appliesDefaultsForOptionalVars() (gas: 17786 → 17786 | 0 0.000%)
━ DeployProtocolScriptTest::test_readConfig_deployerIsTxOrigin() (gas: 15801 → 15801 | 0 0.000%)
━ DeployProtocolScriptTest::test_run_abortsBeforeBroadcastWhenManifestExists() (gas: 22040 → 22040 | 0 0.000%)
━ DeployProtocolScriptTest::test_run_revertsIfDeployerIsForgeDefaultSender() (gas: 15305 → 15305 | 0 0.000%)
━ DeployProtocolScriptTest::test_writeManifest_overwritesWhenForced() (gas: 110634 → 110634 | 0 0.000%)
━ DeployProtocolScriptTest::test_writeManifest_revertsOnExistingFile() (gas: 32033 → 32033 | 0 0.000%)
━ DeployProtocolScriptTest::test_writeManifest_writesAllAddresses() (gas: 92307 → 92307 | 0 0.000%)
━ E2EProtocolTest::test_deployWiring_newContractsWiredAndHandedOff() (gas: 66882 → 66882 | 0 0.000%)
━ Ed25519VerifierTest::test_MalleatedScalarRejected() (gas: 525477 → 525477 | 0 0.000%)
━ Ed25519VerifierTest::test_NonCanonicalYRejected() (gas: 11387 → 11387 | 0 0.000%)
━ Ed25519VerifierTest::test_OffCurvePubKeyRejected() (gas: 14174 → 14174 | 0 0.000%)
━ Ed25519VerifierTest::test_SmallOrderPubKeyRejected() (gas: 40661 → 40661 | 0 0.000%)
━ Ed25519VerifierTest::test_SmallOrderRRejected() (gas: 39201 → 39201 | 0 0.000%)
━ Ed25519VerifierTest::test_ValidVectorsAccepted() (gas: 3003445 → 3003445 | 0 0.000%)
━ Ed25519VerifierTest::test_VerifyRunsUnderStaticcall() (gas: 508245 → 508245 | 0 0.000%)
━ Ed25519VerifierTest::test_WrongLengthSignatureRejected() (gas: 12156 → 12156 | 0 0.000%)
━ Ed25519VerifierTest::test_WrongMessageRejected() (gas: 507932 → 507932 | 0 0.000%)
━ Ed25519VerifierTest::test_WrongPubKeyRejected() (gas: 509119 → 509119 | 0 0.000%)
━ Ed25519VerifierTest::test_WrongRRejected() (gas: 503763 → 503763 | 0 0.000%)
━ Ed25519VerifierTest::test_WrongSRejected() (gas: 508960 → 508960 | 0 0.000%)
━ FeeRouterTest::test_pause_revertsWithoutRole() (gas: 14609 → 14609 | 0 0.000%)
━ FeeRouterTest::test_routeSettlement_distributesThreeLegs() (gas: 232441 → 232441 | 0 0.000%)
━ FeeRouterTest::test_setShares_rejectsSumNot10000() (gas: 14523 → 14523 | 0 0.000%)
━ FeeRouterTest::test_setShares_revertsWithoutRole() (gas: 15219 → 15219 | 0 0.000%)
━ FeeRouterTest::test_setWindowEpochs_revertsWithoutRole() (gas: 14688 → 14688 | 0 0.000%)
━ GovernanceLifecycleTest::test_canary_executorIsTimelock() (gas: 9969 → 9969 | 0 0.000%)
━ InterfaceFreezeTest::test_originAssignment_abiFrozen() (gas: 1298 → 1298 | 0 0.000%)
━ InterfaceFreezeTest::test_paymentChannel_abiFrozen() (gas: 1540 → 1540 | 0 0.000%)
━ InterfaceFreezeTest::test_slashJudge_abiFrozen() (gas: 870 → 870 | 0 0.000%)
━ OriginAssignmentTest::test_activate_revertsBeforeTimelock() (gas: 140524 → 140524 | 0 0.000%)
━ OriginAssignmentTest::test_cancel_clearsPending() (gas: 110536 → 110536 | 0 0.000%)
━ OriginAssignmentTest::test_defaultOpen_addAndRemove() (gas: 78409 → 78409 | 0 0.000%)
━ OriginAssignmentTest::test_defaultOpen_revertsInactive() (gas: 27910 → 27910 | 0 0.000%)
━ OriginAssignmentTest::test_propose_revertsEmpty() (gas: 21925 → 21925 | 0 0.000%)
━ OriginAssignmentTest::test_propose_revertsNonOwner() (gas: 27271 → 27271 | 0 0.000%)
━ OriginAssignmentTest::test_propose_revertsTooMany() (gas: 39410 → 39410 | 0 0.000%)
━ OriginAssignmentTest::test_propose_storesPending() (gas: 133692 → 133692 | 0 0.000%)
━ OriginAssignmentTest::test_revoke_revertsNonMember() (gas: 23619 → 23619 | 0 0.000%)
━ OriginAssignmentTest::test_setMaxOrigins_enforcesBounds() (gas: 13857 → 13857 | 0 0.000%)
━ PaymentChannelTest::test_openChannel_revertsBelowMinDeposit() (gas: 23033 → 23033 | 0 0.000%)
━ PaymentChannelTest::test_openChannel_revertsOnInactiveProvider() (gas: 29784 → 29784 | 0 0.000%)
━ PaymentChannelTest::test_openChannel_revertsWhenPaused() (gas: 47399 → 47399 | 0 0.000%)
━ PaymentChannelTest::test_setDisputeWindow_enforcesBounds() (gas: 24815 → 24815 | 0 0.000%)
━ PaymentChannelTest::test_setFeeRouter_revertsOnEoaRouter() (gas: 18660 → 18660 | 0 0.000%)
━ PaymentChannelTest::test_setFeeRouter_revertsOnZeroAndUnchanged() (gas: 24635 → 24635 | 0 0.000%)
━ PublisherRegistryTest::test_claimContent_multiClaimAcrossNamespaces() (gas: 233820 → 233820 | 0 0.000%)
━ PublisherRegistryTest::test_claimContent_recordsClaim() (gas: 134733 → 134733 | 0 0.000%)
━ PublisherRegistryTest::test_claimContent_revertsForDefaultOpenNamespace() (gas: 13756 → 13756 | 0 0.000%)
━ PublisherRegistryTest::test_claimContent_revertsIfNotOwner() (gas: 66829 → 66829 | 0 0.000%)
━ PublisherRegistryTest::test_claimContent_revertsOnDuplicateSameNamespace() (gas: 135319 → 135319 | 0 0.000%)
━ PublisherRegistryTest::test_constructor_revertsZeroAdmin() (gas: 36674 → 36674 | 0 0.000%)
━ PublisherRegistryTest::test_constructor_setsDefaultsAndRoles() (gas: 19037 → 19037 | 0 0.000%)
━ PublisherRegistryTest::test_createNamespace_assignsIdsFromOne() (gas: 92728 → 92728 | 0 0.000%)
━ PublisherRegistryTest::test_createNamespace_revertsAtCap() (gas: 98581 → 98581 | 0 0.000%)
━ PublisherRegistryTest::test_createNamespace_zeroIsNeverAssigned() (gas: 65471 → 65471 | 0 0.000%)
━ PublisherRegistryTest::test_namespaceOf_emptyForUnclaimed() (gas: 8273 → 8273 | 0 0.000%)
━ PublisherRegistryTest::test_setMaxNamespaces_revertsOutOfBounds() (gas: 17605 → 17605 | 0 0.000%)
━ PublisherRegistryTest::test_setMaxNamespaces_revertsWithoutRole() (gas: 13384 → 13384 | 0 0.000%)
━ PublisherRegistryTest::test_setMaxNamespaces_withinBounds() (gas: 20687 → 20687 | 0 0.000%)
━ PublisherRegistryTest::test_setTransferTimelock_revertsOutOfBounds() (gas: 17706 → 17706 | 0 0.000%)
━ PublisherRegistryTest::test_setTransferTimelock_revertsWithoutRole() (gas: 14763 → 14763 | 0 0.000%)
━ PublisherRegistryTest::test_setTransferTimelock_withinBounds() (gas: 20560 → 20560 | 0 0.000%)
━ PublisherRegistryTest::test_transfer_cancelByOwner() (gas: 78668 → 78668 | 0 0.000%)
━ PublisherRegistryTest::test_transfer_cancelRevertsIfNotOwner() (gas: 93302 → 93302 | 0 0.000%)
━ PublisherRegistryTest::test_transfer_finalizeRevertsIfNotPendingOwner() (gas: 93817 → 93817 | 0 0.000%)
━ PublisherRegistryTest::test_transfer_finalizeRevertsNoPending() (gas: 68544 → 68544 | 0 0.000%)
━ PublisherRegistryTest::test_transfer_fullFlow() (gas: 98658 → 98658 | 0 0.000%)
━ PublisherRegistryTest::test_transfer_initiateRevertsIfNotOwner() (gas: 66923 → 66923 | 0 0.000%)
━ PublisherRegistryTest::test_transfer_initiateRevertsZeroNewOwner() (gas: 64330 → 64330 | 0 0.000%)
━ PublisherRegistryTest::test_transfer_revertsWhenRecipientAtCap() (gas: 150145 → 150145 | 0 0.000%)
━ PublisherRegistryTest::test_transfer_selfTransferExemptFromCap() (gas: 95404 → 95404 | 0 0.000%)
━ SlashJudgeTest::test_blacklist_revertsOnHashMismatch() (gas: 68210 → 68210 | 0 0.000%)
━ SlashJudgeTest::test_blacklist_revertsWhenBlacklistedAfterResponse() (gas: 72559 → 72559 | 0 0.000%)
━ SlashJudgeTest::test_blacklist_revertsWhenNotBlacklisted() (gas: 48632 → 48632 | 0 0.000%)
━ SlashJudgeTest::test_blacklist_revertsWhenSuspended() (gas: 72096 → 72096 | 0 0.000%)
━ SlashJudgeTest::test_blacklist_slashesOnProbeResponse() (gas: 189538 → 189538 | 0 0.000%)
━ SlashJudgeTest::test_blacklist_slashesOnStreamResponse() (gas: 190270 → 190270 | 0 0.000%)
━ SlashJudgeTest::test_constructor_revertsWhenEvidenceAgeExceedsUnbonding() (gas: 366864 → 366864 | 0 0.000%)
━ SlashJudgeTest::test_pause_blocksChallenges() (gas: 58348 → 58348 | 0 0.000%)
━ SlashJudgeTest::test_phantom_revertsOnBadProbeSignature() (gas: 46691 → 46691 | 0 0.000%)
━ SlashJudgeTest::test_phantom_revertsOnEvidenceReplay() (gas: 199102 → 199102 | 0 0.000%)
━ SlashJudgeTest::test_phantom_revertsOnFutureEvidence() (gas: 47528 → 47528 | 0 0.000%)
━ SlashJudgeTest::test_phantom_revertsOnNodeIdMismatch() (gas: 37805 → 37805 | 0 0.000%)
━ SlashJudgeTest::test_phantom_revertsOnStaleEvidence() (gas: 49909 → 49909 | 0 0.000%)
━ SlashJudgeTest::test_phantom_revertsOnUnregisteredNode() (gas: 39027 → 39027 | 0 0.000%)
━ SlashJudgeTest::test_phantom_revertsOutsideTimestampWindow() (gas: 49624 → 49624 | 0 0.000%)
━ SlashJudgeTest::test_phantom_revertsWhenStreamOk() (gas: 53546 → 53546 | 0 0.000%)
━ SlashJudgeTest::test_phantom_slashesAndRoundTripsBond() (gas: 179547 → 179547 | 0 0.000%)
━ SlashJudgeTest::test_rate_revertsWhenNotHigher() (gas: 53581 → 53581 | 0 0.000%)
━ SlashJudgeTest::test_rate_slashesWhenStreamRateHigher() (gas: 172123 → 172123 | 0 0.000%)
━ SlashJudgeTest::test_setChallengeBond_enforcesBounds() (gas: 24689 → 24689 | 0 0.000%)
━ SlashJudgeTest::test_setMaxEvidenceAge_enforcesBoundsAndInvariant() (gas: 40199 → 40199 | 0 0.000%)
━ SlashJudgeTest::test_setters_onlyGovernance() (gas: 13759 → 13759 | 0 0.000%)
━ TestnetFaucetTest::testFuzz_claim_atOrAboveCooldown(uint256) (gas: 91528 → 91528 | 0 0.000%)
━ TestnetFaucetTest::testFuzz_claim_belowCooldown(uint256) (gas: 85389 → 85389 | 0 0.000%)
━ TestnetFaucetTest::test_admin_canGrantAndRevokeRoles() (gas: 56401 → 56401 | 0 0.000%)
━ TestnetFaucetTest::test_claim_blocksReentrancy() (gas: 1550228 → 1550228 | 0 0.000%)
━ TestnetFaucetTest::test_claim_happyPath() (gas: 82821 → 82821 | 0 0.000%)
━ TestnetFaucetTest::test_claim_perCallerCooldownIndependence() (gas: 133478 → 133478 | 0 0.000%)
━ TestnetFaucetTest::test_claim_revertsBeforeCooldown() (gas: 83092 → 83092 | 0 0.000%)
━ TestnetFaucetTest::test_claim_revertsOnInsufficientBalance() (gas: 50715 → 50715 | 0 0.000%)
━ TestnetFaucetTest::test_claim_revertsOneSecondBeforeCooldownBoundary() (gas: 82996 → 82996 | 0 0.000%)
━ TestnetFaucetTest::test_claim_revertsWhenPaused() (gas: 39998 → 39998 | 0 0.000%)
━ TestnetFaucetTest::test_claim_succeedsAfterCooldown() (gas: 90430 → 90430 | 0 0.000%)
━ TestnetFaucetTest::test_claim_succeedsAtExactCooldownBoundary() (gas: 87103 → 87103 | 0 0.000%)
━ TestnetFaucetTest::test_constructor_allowsZeroCooldown() (gas: 1810378 → 1810378 | 0 0.000%)
━ TestnetFaucetTest::test_constructor_revertsOnCooldownExceedingMax() (gas: 1015061 → 1015061 | 0 0.000%)
━ TestnetFaucetTest::test_constructor_revertsOnMainnetChainId() (gas: 988198 → 988198 | 0 0.000%)
━ TestnetFaucetTest::test_constructor_revertsOnZeroAdmin() (gas: 985898 → 985898 | 0 0.000%)
━ TestnetFaucetTest::test_constructor_revertsOnZeroClaimAmount() (gas: 988045 → 988045 | 0 0.000%)
━ TestnetFaucetTest::test_constructor_revertsOnZeroFunding() (gas: 988061 → 988061 | 0 0.000%)
━ TestnetFaucetTest::test_constructor_revertsOnZeroGovernance() (gas: 985864 → 985864 | 0 0.000%)
━ TestnetFaucetTest::test_constructor_revertsOnZeroPauser() (gas: 985954 → 985954 | 0 0.000%)
━ TestnetFaucetTest::test_constructor_revertsOnZeroTokenAddress() (gas: 70468 → 70468 | 0 0.000%)
━ TestnetFaucetTest::test_constructor_revertsOnZeroTreasury() (gas: 987830 → 987830 | 0 0.000%)
━ TestnetFaucetTest::test_constructor_revertsWhenTreasuryNotApproved() (gas: 1110690 → 1110690 | 0 0.000%)
━ TestnetFaucetTest::test_constructor_setsStateAndRoles() (gas: 43070 → 43070 | 0 0.000%)
━ TestnetFaucetTest::test_nonAdmin_cannotGrantRoles() (gas: 17889 → 17889 | 0 0.000%)
━ TestnetFaucetTest::test_pause_blocksClaimUnpauseRestores() (gas: 91691 → 91691 | 0 0.000%)
━ TestnetFaucetTest::test_pause_revertsOnNonPauser() (gas: 14607 → 14607 | 0 0.000%)
━ TestnetFaucetTest::test_setClaimAmount_revertsOnNonGovernance() (gas: 14702 → 14702 | 0 0.000%)
━ TestnetFaucetTest::test_setClaimAmount_revertsOnZero() (gas: 13338 → 13338 | 0 0.000%)
━ TestnetFaucetTest::test_setClaimAmount_updatesAndEmits() (gas: 22083 → 22083 | 0 0.000%)
━ TestnetFaucetTest::test_setCooldown_acceptsMaxCooldown() (gas: 20228 → 20228 | 0 0.000%)
━ TestnetFaucetTest::test_setCooldown_allowsZero() (gas: 94920 → 94920 | 0 0.000%)
━ TestnetFaucetTest::test_setCooldown_revertsOnExceedingMax() (gas: 13790 → 13790 | 0 0.000%)
━ TestnetFaucetTest::test_setCooldown_revertsOnNonGovernance() (gas: 14705 → 14705 | 0 0.000%)
━ TestnetFaucetTest::test_setCooldown_updatesAndEmits() (gas: 22231 → 22231 | 0 0.000%)
━ TestnetFaucetTest::test_timeUntilNext_tracksCooldownWindow() (gas: 82615 → 82615 | 0 0.000%)
━ TestnetFaucetTest::test_timeUntilNext_zeroBeforeFirstClaim() (gas: 10099 → 10099 | 0 0.000%)
━ TestnetFaucetTest::test_unpause_revertsOnNonPauser() (gas: 43483 → 43483 | 0 0.000%)
━ TestnetFaucetTest::test_withdraw_revertsOnInsufficientBalance() (gas: 26877 → 26877 | 0 0.000%)
━ TestnetFaucetTest::test_withdraw_revertsOnNonGovernance() (gas: 17089 → 17089 | 0 0.000%)
━ TestnetFaucetTest::test_withdraw_revertsOnZeroAmount() (gas: 20838 → 20838 | 0 0.000%)
━ TestnetFaucetTest::test_withdraw_revertsOnZeroTo() (gas: 18662 → 18662 | 0 0.000%)
━ TestnetFaucetTest::test_withdraw_transfersAndEmits() (gas: 44129 → 44129 | 0 0.000%)
━ TestnetFaucetTest::test_withdraw_worksWhilePaused() (gas: 68286 → 68286 | 0 0.000%)
━ TokenTest::testFuzz_burn_reducesSupplyByExactAmount(uint256) (gas: 27700 → 27700 | 0 0.000%)
━ TokenTest::test_burnFrom_consumesAllowance() (gas: 38534 → 38534 | 0 0.000%)
━ TokenTest::test_burn_reducesTotalSupplyAndBalance() (gas: 26044 → 26044 | 0 0.000%)
━ TokenTest::test_constructor_metadata() (gas: 17896 → 17896 | 0 0.000%)
━ TokenTest::test_constructor_mintsFullSupplyToHolder() (gas: 12954 → 12954 | 0 0.000%)
━ TokenTest::test_constructor_revertsOnZeroInitialHolder() (gas: 83264 → 83264 | 0 0.000%)
━ TokenTest::test_constructor_totalSupplyConstantMatches() (gas: 9364 → 9364 | 0 0.000%)
━ TokenTest::test_noMintFunctionExposed() (gas: 10765 → 10765 | 0 0.000%)
━ TokenTest::test_noVotesSurfaceExposed() (gas: 11991 → 11991 | 0 0.000%)
━ TokenTest::test_permit_setsAllowance() (gas: 67380 → 67380 | 0 0.000%)
↑ CapacityBondTest::test_creditSlash_escrowsThenDistributes5050AtFinality() (gas: 458249 → 458250 | 1 0.000%)
↑ CapacityBondTest::test_forfeitUnvestedCredit_onUnbond() (gas: 300422 → 300423 | 1 0.000%)
↑ SlashAppealTest::test_grant_newerAppeal_fallsBackToOlderStandingSlash() (gas: 603685 → 603691 | 6 0.001%)
↑ SlashAppealTest::test_open_revertsOnDoubleAppeal() (gas: 486736 → 486748 | 12 0.002%)
↓ SlashAppealTest::test_reject_burnsBondAndDistributesEscrow() (gas: 478618 → 478602 | -16 -0.003%)
↑ CapacityBondTest::test_slash_creditSlash_escalatesAcrossTiers() (gas: 666599 → 666622 | 23 0.003%)
↓ CapacityBondTest::test_slashHitsVestedAndUnvestedTogether() (gas: 476164 → 476143 | -21 -0.004%)
↓ CapacityBondTest::test_appealGrant_unlocksClaimBeforeGateExpiry() (gas: 433691 → 433670 | -21 -0.005%)
↓ CapacityBondTest::test_pendingCreditSlash_reducesOriginalGrant() (gas: 433125 → 433104 | -21 -0.005%)
↑ SlashAppealTest::test_grant_revertsIfNotFastTracked() (gas: 486955 → 486982 | 27 0.006%)
↑ CapacityBondTest::test_slash_stampsSlashedAtEpoch() (gas: 314664 → 314686 | 22 0.007%)
↑ CapacityBondTest::test_slash_tier3_mixedBond_exhaustsActiveTapsUnbonding() (gas: 599418 → 599462 | 44 0.007%)
↑ CapacityBondTest::test_claimVestedCredit_multiSlash_gatedByOlderStandingSlash() (gas: 584065 → 584110 | 45 0.008%)
↓ SlashAppealTest::test_pause_extendsFilingWindow() (gas: 408682 → 408650 | -32 -0.008%)
↑ CapacityBondTest::test_slash_tierEscalation_15then50pct() (gas: 547217 → 547261 | 44 0.008%)
↓ CapacityBondTest::test_forfeitUnvestedCredit_burnsWhenNoTreasury() (gas: 256105 → 256084 | -21 -0.008%)
↑ SlashAppealTest::test_grant_restoresCreditVestingNotLiquid() (gas: 576516 → 576566 | 50 0.009%)
↓ CapacityBondTest::test_slashHitsVestedButUnclaimed() (gas: 443613 → 443570 | -43 -0.010%)
↓ CapacityBondTest::test_claimVestedCredit_succeedsAfterSlashGateExpires() (gas: 442051 → 442008 | -43 -0.010%)
↓ CapacityBondTest::test_claimVestedCredit_revertsWhenSlashedInWindow() (gas: 439019 → 438976 | -43 -0.010%)
↑ SlashAppealTest::test_open_revertsAfterFilingWindow() (gas: 481797 → 481847 | 50 0.010%)
↓ SlashAppealTest::test_uphold_distributesEscrowAndSplitsBond() (gas: 515059 → 515000 | -59 -0.011%)
↑ CapacityBondTest::test_finalizeUnappealedSlash_distributes5050() (gas: 356654 → 356698 | 44 0.012%)
↑ SlashAppealTest::test_frequencyCap_blocksSecondAppealWithinWindow() (gas: 608265 → 608342 | 77 0.013%)
↑ OriginAssignmentTest::test_defaultOpen_setAllowlist() (gas: 172086 → 172108 | 22 0.013%)
↑ CapacityBondTest::test_markAppealOpen_blocksFinalize() (gas: 327281 → 327325 | 44 0.013%)
↑ CapacityBondTest::test_slash_escrowsWithoutDistribution() (gas: 326147 → 326191 | 44 0.013%)
↑ SlashAppealTest::test_grant_requiresGovernance() (gas: 495247 → 495318 | 71 0.014%)
↑ SlashAppealTest::test_open_locksEscrowAndPullsBond() (gas: 490954 → 491027 | 73 0.015%)
↑ SlashAppealTest::test_grant_refundsOperatorAndBondAndClearsZeroOut() (gas: 463212 → 463283 | 71 0.015%)
↑ SlashAppealTest::test_grant_olderAppeal_preservesNewerSlashZeroOut() (gas: 603017 → 603110 | 93 0.015%)
↓ FeeRouterTest::test_routeSettlement_dustRoutesToOperatorWhenBuybackUnset() (gas: 141838 → 141816 | -22 -0.016%)
↑ OriginAssignmentTest::test_activate_onlyGovernance() (gas: 140563 → 140585 | 22 0.016%)
↑ SlashAppealTest::test_open_revertsForNonOperator() (gas: 495568 → 495646 | 78 0.016%)
↑ CapacityBondTest::test_registerNode_succeedsAtCurve() (gas: 415424 → 415491 | 67 0.016%)
↑ CapacityBondTest::test_slash_doesNotEnforceCurve() (gas: 362496 → 362563 | 67 0.018%)
↑ CapacityBondTest::test_settleAppealUpheld_distributes5050() (gas: 348716 → 348782 | 66 0.019%)
↑ CapacityBondTest::test_settleAppealGranted_reverseMiddleSlash_keepsNewest() (gas: 578068 → 578178 | 110 0.019%)
↑ FeeRouterTest::test_routeSettlement_incrementsBytesPerEpoch() (gas: 221457 → 221502 | 45 0.020%)
↓ CapacityBondTest::test_slashId_persistsRecord() (gas: 314968 → 314901 | -67 -0.021%)
↓ CapacityBondTest::test_updateRegion_cooldownAndPrevSnapshot() (gas: 458111 → 458001 | -110 -0.024%)
↓ FeeRouterTest::test_routeSettlement_revertsWithoutRouterRole() (gas: 89208 → 89186 | -22 -0.025%)
↑ FeeRouterTest::test_bytesInWindow_sumsTrailingWindow() (gas: 497291 → 497431 | 140 0.028%)
↑ SlashAppealTest::test_fastTrack_requiresMultisig() (gas: 484575 → 484713 | 138 0.028%)
↓ FeeRouterTest::test_unpause_revertsWithoutRole() (gas: 72166 → 72144 | -22 -0.030%)
↑ CapacityBondTest::test_settleAppealGranted_multiSlash_recomputesThenClears() (gas: 429016 → 429148 | 132 0.031%)
↓ CapacityBondTest::test_genesisCredit_grantWithinWindow() (gas: 139196 → 139153 | -43 -0.031%)
↑ CapacityBondTest::test_requestUnbond_succeedsDownToExactlyCurve() (gas: 208809 → 208876 | 67 0.032%)
↑ CapacityBondTest::test_settleAppealGranted_clearsAndRefunds() (gas: 303422 → 303532 | 110 0.036%)
↑ CapacityBondTest::test_firstBondedAt_immutableAcrossReBonds() (gas: 111447 → 111491 | 44 0.039%)
↓ CapacityBondTest::test_claimVestedCredit_multiClaimFollowsLinearCurve() (gas: 219111 → 219024 | -87 -0.040%)
↓ CapacityBondTest::test_claimVestedCredit_movesIntoActiveBond() (gas: 214548 → 214461 | -87 -0.041%)
↑ CapacityBondTest::test_firstBondedAt_setsOnFirstBond() (gas: 102513 → 102557 | 44 0.043%)
↓ CapacityBondTest::test_forfeitUnvestedCredit_doesNotClawBackVestedUnclaimed() (gas: 291756 → 291625 | -131 -0.045%)
↓ CapacityBondTest::test_claimVestedCredit_revertsWhenNoActiveBond() (gas: 144549 → 144484 | -65 -0.045%)
↑ BuybackBurnerTest::test_constructor_grantsAdminAndGovernanceRoles() (gas: 14866 → 14873 | 7 0.047%)
↑ DeployProtocolTest::test_roleMatrix_pauserIsEmergencyMultisig() (gas: 45635 → 45657 | 22 0.048%)
↑ CapacityBondTest::test_declareMbps_revertsWhenBondBelowCurve() (gas: 131783 → 131850 | 67 0.051%)
↓ CapacityBondTest::test_genesisCredit_revertsAfterWindow() (gas: 82827 → 82784 | -43 -0.052%)
↑ DeployProtocolTest::test_roleMatrix_timelockHoldsGovernanceOnEveryTarget() (gas: 41952 → 41974 | 22 0.052%)
↑ DeployProtocolTest::test_roleMatrix_timelockHoldsDefaultAdminOnEveryTarget() (gas: 41824 → 41846 | 22 0.053%)
↑ CapacityBondTest::test_registerNode_revertsWhenBondBelowCurve() (gas: 207450 → 207561 | 111 0.054%)
↑ OriginAssignmentTest::test_propose_revertsInactiveOperator() (gas: 39819 → 39841 | 22 0.055%)
↑ CapacityBondTest::test_requestUnbond_revertsWhenItDropsBelowCurve() (gas: 160305 → 160394 | 89 0.056%)
↓ BuybackBurnerTest::test_setPool_emitsUpdateEvent() (gas: 24953 → 24938 | -15 -0.060%)
↑ CapacityBondTest::test_declaredMbps_storesValue() (gas: 147168 → 147258 | 90 0.061%)
↑ CapacityBondTest::test_declareMbps_succeedsExactlyAtCurve() (gas: 147146 → 147236 | 90 0.061%)
↑ OriginAssignmentTest::test_propose_revertsDuplicate() (gas: 34896 → 34918 | 22 0.063%)
↑ CapacityBondTest::test_setAlpha_updatesCurveAndEmits() (gas: 33844 → 33866 | 22 0.065%)
↑ DeployProtocolTest::test_roleMatrix_deployerHoldsNoRoleAnywhere() (gas: 66902 → 66946 | 44 0.066%)
↓ FeeRouterTest::test_setWindowEpochs_enforcesBounds() (gas: 32780 → 32758 | -22 -0.067%)
↑ OriginAssignmentTest::test_activate_revertsOperatorBlacklisted() (gas: 173723 → 173841 | 118 0.068%)
↓ OriginAssignmentTest::test_propose_overwriteReplacesPending() (gas: 128820 → 128731 | -89 -0.069%)
↑ CapacityBondTest::test_capacityBand_floorAlwaysBelowCeiling() (gas: 29297 → 29319 | 22 0.075%)
↑ CapacityBondTest::test_setMinCapacity_updatesBandAndEmits() (gas: 166870 → 167005 | 135 0.081%)
↑ CapacityBondTest::test_declareMbps_emitsOldAndNewValue() (gas: 158167 → 158302 | 135 0.085%)
↓ SlashAppealTest::test_open_revertsUnknownSlash() (gas: 23776 → 23755 | -21 -0.088%)
↑ GovernanceLifecycleTest::test_canary_governanceRoleHandoff() (gas: 99056 → 99144 | 88 0.089%)
↑ OriginAssignmentTest::test_setAssignmentTimelock_enforcesBounds() (gas: 24737 → 24759 | 22 0.089%)
↑ BuybackBurnerTest::test_executeBuyback_revertsWhenPaused() (gas: 73094 → 73161 | 67 0.092%)
↓ CapacityBondTest::test_genesisCredit_vestsLinearly() (gas: 141606 → 141475 | -131 -0.093%)
↓ CapacityBondTest::test_genesisCredit_fullVestAfterDuration() (gas: 141326 → 141195 | -131 -0.093%)
↓ CapacityBondTest::test_unpause_revertsWithoutRole() (gas: 94612 → 94524 | -88 -0.093%)
↓ BuybackBurnerTest::test_executeBuyback_revertsWithoutKeeperRole() (gas: 64298 → 64237 | -61 -0.095%)
↑ GovernanceLifecycleTest::test_lifecycle_SlashAppeal_setAppealBond_outOfBounds() (gas: 596948 → 597519 | 571 0.096%)
↑ GovernanceLifecycleTest::test_lifecycle_SlashAppeal_setAppealBond_happy() (gas: 591081 → 591652 | 571 0.097%)
↑ GovernanceLifecycleTest::test_lifecycle_DecdnGovernor_setVoteCapBps_outOfBounds() (gas: 636214 → 636830 | 616 0.097%)
↑ GovernanceLifecycleTest::test_lifecycle_DecdnGovernor_setAgeRampMonths_outOfBounds() (gas: 636172 → 636788 | 616 0.097%)
↑ GovernanceLifecycleTest::test_lifecycle_DecdnGovernor_setVoteCapBps_happy() (gas: 630461 → 631077 | 616 0.098%)
↑ GovernanceLifecycleTest::test_lifecycle_DecdnGovernor_setAgeRampMonths_happy() (gas: 630454 → 631070 | 616 0.098%)
↑ GovernanceLifecycleTest::test_lifecycle_FeeRouter_setSharesAndDestinations_happy() (gas: 621947 → 622563 | 616 0.099%)
↑ GovernanceLifecycleTest::test_lifecycle_FeeRouter_setWindowEpochs_happy() (gas: 610783 → 611399 | 616 0.101%)
↑ GovernanceLifecycleTest::test_lifecycle_ContentBlacklist_registerRegionalBody_happy() (gas: 610550 → 611166 | 616 0.101%)
↑ GovernanceLifecycleTest::test_lifecycle_ContentBlacklist_setOriginBlacklist_happy() (gas: 609684 → 610300 | 616 0.101%)
↑ GovernanceLifecycleTest::test_lifecycle_FeeRouter_setShares_happy() (gas: 608092 → 608708 | 616 0.101%)
↑ GovernanceLifecycleTest::test_lifecycle_CapacityBond_setMultiaddrUpdateCooldown_happy() (gas: 605793 → 606409 | 616 0.102%)
↑ GovernanceLifecycleTest::test_lifecycle_ContentBlacklist_removeHashGlobal_outOfBounds() (gas: 599178 → 599794 | 616 0.103%)
↑ GovernanceLifecycleTest::test_lifecycle_FeeRouter_setSharesAndDestinations_outOfBounds() (gas: 597638 → 598254 | 616 0.103%)
↑ GovernanceLifecycleTest::test_lifecycle_ContentBlacklist_setOriginBlacklist_outOfBounds() (gas: 597472 → 598088 | 616 0.103%)
↑ GovernanceLifecycleTest::test_lifecycle_PublisherRegistry_setNamespaceTransferTimelock_outOfBounds() (gas: 596988 → 597604 | 616 0.103%)
↑ GovernanceLifecycleTest::test_lifecycle_ContentBlacklist_setAppealBond_outOfBounds() (gas: 596951 → 597567 | 616 0.103%)
↑ GovernanceLifecycleTest::test_lifecycle_PublisherRegistry_setMaxNamespacesPerPublisher_outOfBounds() (gas: 596946 → 597562 | 616 0.103%)
↑ GovernanceLifecycleTest::test_lifecycle_FeeRouter_setWindowEpochs_outOfBounds() (gas: 596811 → 597427 | 616 0.103%)
↑ GovernanceLifecycleTest::test_lifecycle_SlashAppeal_setChallengerIncentivePool_outOfBounds() (gas: 596777 → 597393 | 616 0.103%)
↑ GovernanceLifecycleTest::test_lifecycle_ContentBlacklist_addHashGlobal_outOfBounds() (gas: 596630 → 597246 | 616 0.103%)
↑ GovernanceLifecycleTest::test_lifecycle_FeeRouter_setBuybackBurner_outOfBounds() (gas: 596542 → 597158 | 616 0.103%)
↑ GovernanceLifecycleTest::test_lifecycle_FeeRouter_setShares_outOfBounds() (gas: 596435 → 597051 | 616 0.103%)
↑ GovernanceLifecycleTest::test_lifecycle_CapacityBond_setMaxMultiaddrSize_outOfBounds() (gas: 594605 → 595221 | 616 0.104%)
↑ GovernanceLifecycleTest::test_lifecycle_CapacityBond_setClaimSlashGateEpochs_outOfBounds() (gas: 594581 → 595197 | 616 0.104%)
↑ GovernanceLifecycleTest::test_lifecycle_CapacityBond_setUnbondingPeriod_outOfBounds() (gas: 594542 → 595158 | 616 0.104%)
↑ GovernanceLifecycleTest::test_lifecycle_CapacityBond_setMultiaddrUpdateCooldown_outOfBounds() (gas: 594466 → 595082 | 616 0.104%)
↑ GovernanceLifecycleTest::test_lifecycle_FeeRouter_setTreasury_outOfBounds() (gas: 594287 → 594903 | 616 0.104%)
↑ OriginAssignmentTest::test_defaultOpen_onlyGovernance() (gas: 21147 → 21169 | 22 0.104%)
↑ GovernanceLifecycleTest::test_lifecycle_SlashAppeal_setChallengerIncentivePool_happy() (gas: 591497 → 592113 | 616 0.104%)
↑ GovernanceLifecycleTest::test_lifecycle_PublisherRegistry_setMaxNamespacesPerPublisher_happy() (gas: 591346 → 591962 | 616 0.104%)
↑ GovernanceLifecycleTest::test_lifecycle_PublisherRegistry_setNamespaceTransferTimelock_happy() (gas: 591262 → 591878 | 616 0.104%)
↑ GovernanceLifecycleTest::test_lifecycle_ContentBlacklist_setAppealBond_happy() (gas: 591119 → 591735 | 616 0.104%)
↑ GovernanceLifecycleTest::test_lifecycle_FeeRouter_setTreasury_happy() (gas: 589039 → 589655 | 616 0.105%)
↑ GovernanceLifecycleTest::test_lifecycle_FeeRouter_setBuybackBurner_happy() (gas: 589013 → 589629 | 616 0.105%)
↑ GovernanceLifecycleTest::test_lifecycle_CapacityBond_setClaimSlashGateEpochs_happy() (gas: 588888 → 589504 | 616 0.105%)
↑ GovernanceLifecycleTest::test_lifecycle_CapacityBond_setMinBond_happy() (gas: 588764 → 589380 | 616 0.105%)
↑ GovernanceLifecycleTest::test_lifecycle_CapacityBond_setMinCapacityMbps_happy() (gas: 588739 → 589355 | 616 0.105%)
↑ GovernanceLifecycleTest::test_lifecycle_CapacityBond_setMaxMultiaddrSize_happy() (gas: 588630 → 589246 | 616 0.105%)
↑ OriginAssignmentTest::test_activate_revertsNoPending() (gas: 20987 → 21009 | 22 0.105%)
↑ GovernanceLifecycleTest::test_lifecycle_CapacityBond_setMinBond_outOfBounds() (gas: 594537 → 595175 | 638 0.107%)
↑ GovernanceLifecycleTest::test_lifecycle_CapacityBond_setRegionStabilityWindow_outOfBounds() (gas: 594516 → 595154 | 638 0.107%)
↑ GovernanceLifecycleTest::test_lifecycle_CapacityBond_setMinCapacityMbps_outOfBounds() (gas: 594514 → 595152 | 638 0.107%)
↑ GovernanceLifecycleTest::test_lifecycle_CapacityBond_setMaxCapacityMbps_outOfBounds() (gas: 594492 → 595130 | 638 0.107%)
↑ GovernanceLifecycleTest::test_lifecycle_CapacityBond_setUnbondingPeriod_happy() (gas: 588658 → 589296 | 638 0.108%)
↑ GovernanceLifecycleTest::test_lifecycle_CapacityBond_setMaxCapacityMbps_happy() (gas: 588588 → 589226 | 638 0.108%)
↑ GovernanceLifecycleTest::test_lifecycle_CapacityBond_setTreasury_happy() (gas: 606105 → 606765 | 660 0.109%)
↑ CapacityBondTest::test_declareMbps_acceptsFloorAndCeiling() (gas: 161019 → 161199 | 180 0.112%)
↑ GovernanceLifecycleTest::test_lifecycle_CapacityBond_setRegionStabilityWindow_happy() (gas: 588634 → 589294 | 660 0.112%)
↓ FeeRouterTest::test_setSharesAndDestinations_revertsWithoutRole() (gas: 19569 → 19547 | -22 -0.112%)
↑ OriginAssignmentTest::test_activate_blacklistSkippedWhenUnset() (gas: 2045181 → 2047543 | 2362 0.115%)
↑ BuybackBurnerTest::test_setVault_emitsUpdateEvent() (gas: 24896 → 24925 | 29 0.116%)
↑ CapacityBondTest::test_escrowHooks_requireSlashAppealRole() (gas: 17017 → 17039 | 22 0.129%)
↑ OriginAssignmentTest::test_prune_revertsWhenBlacklistUnset() (gas: 1862769 → 1865198 | 2429 0.130%)
↑ ContentBlacklistTest::test_fullAppealFlow_ratifyRemovesHash() (gas: 275665 → 276038 | 373 0.135%)
↓ FeeRouterTest::test_setShares_rejectsNonZeroShareWithoutDestination() (gas: 16239 → 16217 | -22 -0.135%)
↑ ContentBlacklistTest::test_hasActiveAppeal_clearedOnReverse() (gas: 254985 → 255340 | 355 0.139%)
↑ ContentBlacklistTest::test_reverseAppeal_clearsSuspendedAndBurnsBond() (gas: 261664 → 262037 | 373 0.143%)
↑ BuybackBurnerTest::test_pause_revertsWithoutPauserRole() (gas: 11912 → 11929 | 17 0.143%)
↑ CapacityBondTest::test_setMaxMultiaddrSize_revertsWithoutRole() (gas: 14977 → 14999 | 22 0.147%)
↑ CapacityBondTest::test_setUnbondingPeriod_revertsWithoutRole() (gas: 14913 → 14935 | 22 0.148%)
↑ CapacityBondTest::test_setClaimSlashGateEpochs_revertsWithoutRole() (gas: 14824 → 14846 | 22 0.148%)
↑ CapacityBondTest::test_setMultiaddrUpdateCooldown_revertsWithoutRole() (gas: 14822 → 14844 | 22 0.148%)
↓ FeeRouterTest::test_setBuybackBurner_revertsWithoutRole() (gas: 14720 → 14698 | -22 -0.149%)
↑ GovernanceLifecycleTest::test_canary_governorVoteWeightWired() (gas: 129769 → 129967 | 198 0.153%)
↑ CapacityBondTest::test_setKAlpha_orderingMatters() (gas: 56002 → 56090 | 88 0.157%)
↑ PaymentChannelTest::test_setters_onlyGovernance() (gas: 13976 → 13998 | 22 0.157%)
↑ OriginAssignmentTest::test_setContentBlacklist_rejectsZero() (gas: 13451 → 13473 | 22 0.164%)
↑ CapacityBondTest::test_bondRequired_zeroForZeroMbps() (gas: 13161 → 13183 | 22 0.167%)
↑ CapacityBondTest::test_setMaxCapacity_acceptsInclusiveBounds() (gas: 24407 → 24451 | 44 0.180%)
↑ BuybackBurnerTest::test_constructor_revertsOnZeroToken() (gas: 67829 → 67964 | 135 0.199%)
↑ CapacityBondTest::test_setK_revertsWhenGbpsTierOutOfRange() (gas: 43902 → 43990 | 88 0.200%)
↑ CapacityBondTest::test_curveDefaults() (gas: 10624 → 10646 | 22 0.207%)
↓ CapacityBondTest::test_capacityBand_defaults() (gas: 10622 → 10600 | -22 -0.207%)
↓ BuybackBurnerTest::test_executeBuyback_revertsZeroAmount() (gas: 20705 → 20661 | -44 -0.213%)
↑ CapacityBondTest::test_setMaxCapacity_updatesBandAndEmits() (gas: 31040 → 31107 | 67 0.216%)
↑ PaymentChannelTest::test_getRateBounds_returnsConfigured() (gas: 9890 → 9912 | 22 0.222%)
↑ CapacityBondTest::test_setCurve_onlyGovernance() (gas: 19416 → 19460 | 44 0.227%)
↑ CapacityBondTest::test_setMinCapacity_revertsOutOfBounds() (gas: 18537 → 18581 | 44 0.237%)
↑ CapacityBondTest::test_setMaxCapacity_revertsOutOfBounds() (gas: 18329 → 18373 | 44 0.240%)
↑ CapacityBondTest::test_setK_updatesCurveAndEmits() (gas: 35561 → 35649 | 88 0.247%)
↑ CapacityBondTest::test_declareMbps_revertsAboveCeiling() (gas: 18017 → 18062 | 45 0.250%)
↑ CapacityBondTest::test_declareMbps_revertsBelowFloor() (gas: 17950 → 17995 | 45 0.251%)
↑ CapacityBondTest::test_declareMbps_revertsZero() (gas: 17895 → 17940 | 45 0.251%)
↓ SlashAppealTest::test_cleanup_openLapse_upholds() (gas: 474119 → 472918 | -1201 -0.253%)
↓ DeployProtocolTest::test_emergencyMultisig_canPauseAndBlockEntrypoint() (gas: 48534 → 48410 | -124 -0.255%)
↑ BuybackBurnerTest::test_unpause_revertsWithoutPauserRole() (gas: 23849 → 23910 | 61 0.256%)
↓ SlashAppealTest::test_cleanup_fastTrackedLapse_grantsOperatorFavorable() (gas: 456307 → 455127 | -1180 -0.259%)
↑ BuybackBurnerTest::test_constructor_revertsOnZeroAdmin() (gas: 67810 → 67989 | 179 0.264%)
↑ BuybackBurnerTest::test_constructor_revertsOnZeroUsdc() (gas: 67793 → 67972 | 179 0.264%)
↑ CapacityBondTest::test_setTreasury_revertsWithoutRole() (gas: 14919 → 14963 | 44 0.295%)
↑ CapacityBondTest::test_setMinBond_revertsWithoutRole() (gas: 14846 → 14890 | 44 0.296%)
↑ CapacityBondTest::test_setRegionStabilityWindow_revertsWithoutRole() (gas: 14845 → 14889 | 44 0.296%)
↑ CapacityBondTest::test_bondRequired_matchesAdrWorkedExamples() (gas: 29688 → 29776 | 88 0.296%)
↑ PaymentChannelTest::test_constructor_revertsOnDisputeWindowOutOfBounds() (gas: 76787 → 77036 | 249 0.324%)
↑ CapacityBondTest::test_setCapacity_onlyGovernance() (gas: 19635 → 19701 | 66 0.336%)
↑ DeployProtocolTest::test_roleMatrix_emergencyMultisigGrants() (gas: 19503 → 19569 | 66 0.338%)
↑ PaymentChannelTest::test_constructor_revertsOnZeroAdmin() (gas: 71702 → 71951 | 249 0.347%)
↑ GovernanceLifecycleTest::test_lifecycle_ContentBlacklist_removeHashGlobal_happy() (gas: 993743 → 997238 | 3495 0.352%)
↑ GovernanceLifecycleTest::test_lifecycle_ContentBlacklist_removeOperator_happy() (gas: 1022125 → 1025729 | 3604 0.353%)
↑ PaymentChannelTest::test_constructor_revertsOnEoaFeeRouter() (gas: 76787 → 77058 | 271 0.353%)
↑ E2EProtocolTest::test_e2e_registerSettleSlashEjectAppeal() (gas: 1468598 → 1474331 | 5733 0.390%)
↑ ContentBlacklistTest::test_addHashRegional_revertsWithoutRegionalBodyRole() (gas: 14684 → 14750 | 66 0.449%)
↑ FeeRouterTest::test_setTreasury_revertsWithoutRole() (gas: 14696 → 14763 | 67 0.456%)
↑ GovernanceLifecycleTest::test_lifecycle_ContentBlacklist_addOperator_happy() (gas: 637690 → 640678 | 2988 0.469%)
↑ CapacityBondTest::test_bondRequired_strictlyMonotonic() (gas: 37554 → 37730 | 176 0.469%)
↑ GovernanceLifecycleTest::test_lifecycle_ContentBlacklist_addHashGlobal_happy() (gas: 609043 → 611922 | 2879 0.473%)
↑ DeployProtocolTest::test_crossContractWiring_genesisGrantorIsTimelock() (gas: 17075 → 17165 | 90 0.527%)
↑ E2EProtocolTest::test_e2e_blacklistEjectsOperator() (gas: 417879 → 420295 | 2416 0.578%)
↑ BuybackBurnerTest::test_setVault_revertsWithoutGovernanceRole() (gas: 12054 → 12129 | 75 0.622%)
↑ FeeRouterTest::test_bytesInWindow_zeroWindowReturnsZero() (gas: 9326 → 9387 | 61 0.654%)
↑ PaymentChannelTest::test_normalDispute_doesNotExtend() (gas: 317503 → 319584 | 2081 0.655%)
↑ PaymentChannelTest::test_dispute_higherNonceWins() (gas: 307630 → 309711 | 2081 0.676%)
↑ PaymentChannelTest::test_dispute_revertsOnAmountExceedingDeposit() (gas: 303144 → 305225 | 2081 0.686%)
↑ PaymentChannelTest::test_dispute_revertsOnBytesRegression() (gas: 302891 → 304972 | 2081 0.687%)
↑ PaymentChannelTest::test_dispute_revertsOnAmountRegression() (gas: 302754 → 304835 | 2081 0.687%)
↑ PaymentChannelTest::test_dispute_revertsOnStaleNonce() (gas: 300180 → 302261 | 2081 0.693%)
↑ PaymentChannelTest::test_dispute_revertsAfterDeadline() (gas: 295195 → 297276 | 2081 0.705%)
↑ PaymentChannelTest::test_settle_revertsBeforeDisputeDeadline() (gas: 292432 → 294513 | 2081 0.712%)
↑ PaymentChannelTest::test_withdraw_acceptsErc1271Signature() (gas: 711964 → 717406 | 5442 0.764%)
↑ PaymentChannelTest::test_close_revertsOnAmountExceedingDeposit() (gas: 221040 → 223121 | 2081 0.941%)
↑ PaymentChannelTest::test_withdraw_revertsOnAmountExceedingDeposit() (gas: 220800 → 222881 | 2081 0.942%)
↑ PaymentChannelTest::test_openChannel_derivesIdAndIncrementsNonce() (gas: 219442 → 221523 | 2081 0.948%)
↑ GovernanceLifecycleTest::test_lifecycle_ContentBlacklist_addOperator_outOfBounds() (gas: 596767 → 602436 | 5669 0.950%)
↑ PaymentChannelTest::test_zeroVoucherClose_refundsFullDeposit() (gas: 216232 → 218313 | 2081 0.962%)
↑ PaymentChannelTest::test_withdraw_revertsOnBadSignature() (gas: 213634 → 215715 | 2081 0.974%)
↑ PaymentChannelTest::test_reclaimExpired_revertsBeforeExpiry() (gas: 204176 → 206190 | 2014 0.986%)
↑ PaymentChannelTest::test_close_revertsAfterExpiry() (gas: 209040 → 211121 | 2081 0.996%)
↑ PaymentChannelTest::test_withdraw_onlyProvider() (gas: 208846 → 210927 | 2081 0.996%)
↑ PaymentChannelTest::test_close_thirdPartyCannotClose() (gas: 210915 → 213018 | 2103 0.997%)
↑ CapacityBondTest::testFuzz_bondRequired_monotonic(uint256,uint256) (gas: 19427 → 19622 | 195 1.004%)
↑ PaymentChannelTest::test_topUp_onlyClient() (gas: 204390 → 206621 | 2231 1.092%)
↑ PaymentChannelTest::test_dispute_revertsOnByteOnlyAdvance() (gas: 483308 → 488772 | 5464 1.131%)
↑ PaymentChannelTest::test_close_atWatermarkNonce_succeeds() (gas: 471986 → 477450 | 5464 1.158%)
↑ BuybackBurnerTest::test_setPool_revertsWithoutGovernanceRole() (gas: 12132 → 12273 | 141 1.162%)
↑ PaymentChannelTest::test_settle_fullyWithdrawn_noRouterCall() (gas: 467688 → 473130 | 5442 1.164%)
↑ PaymentChannelTest::test_close_revertsOnByteOnlyAdvance() (gas: 464920 → 470362 | 5442 1.171%)
↑ PaymentChannelTest::test_withdraw_revertsWhenDeltaZero() (gas: 464290 → 469732 | 5442 1.172%)
↑ PaymentChannelTest::test_withdraw_revertsOnBytesRegression() (gas: 463839 → 469281 | 5442 1.173%)
↑ PaymentChannelTest::test_withdraw_revertsOnNonMonotonicNonce() (gas: 463515 → 468957 | 5442 1.174%)
↑ DeployProtocolTest::test_assertNoBackDoors_revertsWhenHandoffIncomplete() (gas: 24644804 → 24934827 | 290023 1.177%)
↑ PaymentChannelTest::test_withdraw_routesDeltaAndAdvancesWatermark() (gas: 460090 → 465532 | 5442 1.183%)
↑ PaymentChannelTest::test_zeroVoucherClose_disabledAfterWithdraw() (gas: 457488 → 462930 | 5442 1.190%)
↑ PaymentChannelTest::test_openChannel_distinctIdsAcrossProviders() (gas: 347252 → 351414 | 4162 1.199%)
↑ PaymentChannelTest::test_reclaimExpired_refundsRemainderToClient() (gas: 446830 → 452272 | 5442 1.218%)
↑ PaymentChannelTest::test_voucher_rejectedOnWrongChannelId() (gas: 335707 → 339891 | 4184 1.246%)
↑ PaymentChannelTest::test_close_then_settle_routesAndRefunds() (gas: 420622 → 426064 | 5442 1.294%)
↑ PaymentChannelTest::testFuzz_settle_refundEqualsDepositMinusClaimed(uint256,uint256) (gas: 410648 → 416090 | 5442 1.325%)
↑ PaymentChannelTest::test_settle_amountEqualsDeposit_zeroRefund() (gas: 405432 → 410874 | 5442 1.342%)
↑ PaymentChannelTest::testFuzz_withdrawThenSettle_partitionsClaim(uint256,uint256,uint256,uint256) (gas: 546319 → 555056 | 8737 1.599%)
↑ PaymentChannelTest::test_withdraw_secondWithdrawRoutesOnlyIncrement() (gas: 546054 → 554879 | 8825 1.616%)
↑ PaymentChannelTest::test_close_afterWithdraw_settleRoutesRemainderOnly() (gas: 538591 → 547394 | 8803 1.634%)
↑ PaymentChannelTest::test_paused_exitsStillCallable() (gas: 659037 → 671201 | 12164 1.846%)
↑ PaymentChannelTest::test_topUp_increasesDeposit() (gas: 222520 → 226710 | 4190 1.883%)
↑ OriginAssignmentTest::test_activate_revertsOperatorWentInactive() (gas: 152943 → 155953 | 3010 1.968%)
↑ OriginAssignmentTest::test_prune_removesBlacklistedOperator() (gas: 243079 → 248023 | 4944 2.034%)
↑ OriginAssignmentTest::test_revoke_byPublisherAndGovernance() (gas: 232436 → 237252 | 4816 2.072%)
↑ OriginAssignmentTest::test_activate_replacesPreviousSet() (gas: 344888 → 352112 | 7224 2.095%)
↑ OriginAssignmentTest::test_activate_setsAuthorizedSet() (gas: 220067 → 224900 | 4833 2.196%)
↑ OriginAssignmentTest::test_prune_revertsWhenNotBlacklisted() (gas: 220747 → 226404 | 5657 2.563%)
↑ ContentBlacklistTest::test_addOperator_callsEjectOnCapacityBond() (gas: 91570 → 93920 | 2350 2.566%)
↑ PaymentChannelTest::test_setFeeRouter_updatesTarget() (gas: 284490 → 292460 | 7970 2.802%)
↑ SlashAppealTest::test_uphold_poolUnset_burnsFullBond() (gas: 2175009 → 2249371 | 74362 3.419%)
↑ BuybackBurnerTest::test_executeBuyback_revertsSwapReportMismatch() (gas: 110981 → 116470 | 5489 4.946%)
↑ ContentBlacklistTest::test_removeHashRegional_blocksGlobalRegionEntries() (gas: 44419 → 46682 | 2263 5.095%)
↑ BuybackBurnerTest::test_executeBuyback_happyPath_burnsAndEmits() (gas: 105272 → 110748 | 5476 5.202%)
↓ ContentBlacklistTest::test_hasActiveAppeal_clearedOnReject() (gas: 433926 → 410381 | -23545 -5.426%)
↑ ContentBlacklistTest::test_addHashRegional_globalTakesPrecedence() (gas: 41980 → 44310 | 2330 5.550%)
↑ PaymentChannelTest::test_forcedInclusion_doesNotExtendTwice() (gas: 2756694 → 2916491 | 159797 5.797%)
↑ PaymentChannelTest::test_forcedInclusion_noExtendWhenAmpleTimeRemains() (gas: 2742648 → 2902445 | 159797 5.826%)
↑ PaymentChannelTest::test_forcedInclusion_extendsDeadlineOnce() (gas: 2734132 → 2893929 | 159797 5.845%)
↑ ContentBlacklistTest::test_addHashGlobal_andQuery() (gas: 38191 → 40454 | 2263 5.925%)
↓ ContentBlacklistTest::test_openBlacklistAppeal_revertsDuplicatePerHash() (gas: 356697 → 334316 | -22381 -6.275%)
↓ ContentBlacklistTest::test_rejectAppeal_burnsBond() (gas: 247882 → 229508 | -18374 -7.412%)
↓ ContentBlacklistTest::test_hasActiveAppeal_clearedOnLapseOpen() (gas: 242221 → 223830 | -18391 -7.593%)
↑ BuybackBurnerTest::test_executeBuyback_revertsSwapNotImplementedWhenActualDeltaIsZero() (gas: 60069 → 65569 | 5500 9.156%)
↓ PublisherRegistryTest::testFuzz_createNamespace_idsAreSequentialAndOwned(uint8) (gas: 441404 → 371835 | -69569 -15.761%)
↑ BuybackBurnerTest::test_executeBuyback_revertsPoolNotWiredWhenVaultUnset() (gas: 840424 → 973299 | 132875 15.810%)
↑ BuybackBurnerTest::test_executeBuyback_revertsPoolNotWiredWhenPoolUnset() (gas: 840272 → 973169 | 132897 15.816%)

New tests:
  + BuybackBurnerTest::test_executeBuyback_revertsWhenAmountExceedsBalance()
  + BuybackBurnerTest::test_executeBuyback_revertsZeroMinOut()
  + BuybackBurnerTest::test_rescueUSDC_revertsOnZeroAmount()
  + BuybackBurnerTest::test_rescueUSDC_revertsOnZeroRecipient()
  + BuybackBurnerTest::test_rescueUSDC_revertsWithoutGovernanceRole()
  + BuybackBurnerTest::test_rescueUSDC_transfersToRecipient()
  + ContentBlacklistTest::test_addHash_revertsWhileAppealActive()
  + ContentBlacklistTest::test_regionalCap_countsFastTrackedNotOpen()
  + FeeRouterTest::test_bytesInWindow_clampsOversizedWindow()
  + OriginAssignmentTest::test_activate_revertsOperatorBlacklistedViaOperatorMapping()
  + OriginAssignmentTest::test_prune_removesOperatorBlacklistedViaOperatorMapping()
  + PaymentChannelTest::test_route_zeroesResidualAllowanceAfterUnderPull()
  + PaymentChannelTest::test_topUp_revertsWhenPaused()
  + SlashAppealTest::test_forceResolveStuckAppeal_resolvesAfterRoleRevoked()
  + SlashAppealTest::test_forceResolveStuckAppeal_revertsWhenNotAppealOpen()
  + SlashAppealTest::test_forceResolveStuckAppeal_revertsWithoutGovernanceRole()
  + SlashAppealTest::test_slashAppealPause_extendsCapacityBondFilingWindow()

--------------------------------------------------------------------------------
Total tests: 459, ↑ 221, ↓ 42, ━ 196
Overall gas change: 1250288 (0.751%)

Run: 26788065308

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR addresses High + Medium severity security-audit findings in contracts/ by hardening settlement/allowance flows, unifying pause-time accounting across the slashing path, tightening blacklist/appeal invariants, and updating docs/tests to match ADR-driven behavior.

Changes:

  • Slashing: unify pause-time accounting into CapacityBond.pausedTotal, add governance escape hatch for wedged appeals, and harden bond distribution on uphold.
  • Payment/fees & buyback: fee-on-transfer-safe deposit accounting, stricter pause semantics, allowance hygiene, FeeRouter window clamping, and BuybackBurner guardrails + USDC rescue.
  • Blacklist/origin: prevent re-adding hashes during live appeals, refine regional-cap semantics, and ensure OriginAssignment consults both blacklist mappings.

Reviewed changes

Copilot reviewed 16 out of 16 changed files in this pull request and generated no comments.

Show a summary per file
File Description
contracts/src/FeeRouter.sol Clamp window length; (needs fix) current window-loop math can overflow on extreme endEpoch.
contracts/test/FeeRouter.t.sol Adds regression coverage for oversized-window clamping.
contracts/src/PaymentChannel.sol Credits measured USDC deltas for deposits/top-ups; adds pause gating; resets router allowances.
contracts/test/PaymentChannel.t.sol Adds tests for pause-gated topUp and residual-allowance zeroing.
contracts/src/BuybackBurner.sol Adds minOut/balance guards and rescueUSDC for stranded funds recovery.
contracts/test/BuybackBurner.t.sol Adds coverage for new guards and rescueUSDC behavior/authorization.
contracts/src/SlashAppeal.sol Uses combined pause accumulator from CapacityBond; credits pause time into CapacityBond; degrades pool transfer failures to burn.
contracts/test/SlashAppeal.t.sol Adds tests for pause-time extension into filing window and governance force-resolve escape hatch.
contracts/src/CapacityBond.sol Makes pausedTotal the combined accumulator; adds creditPauseTime and forceResolveStuckAppeal.
contracts/src/ContentBlacklist.sol Enforces cap only on fast-track; prevents _addHash during active appeals; makes addOperator nonReentrant.
contracts/test/ContentBlacklist.t.sol Updates tests for fast-track-only cap counting and active-appeal re-add revert.
contracts/src/OriginAssignment.sol Consults both origin and operator blacklist mappings via _isBlacklisted.
contracts/test/OriginAssignment.t.sol Adds tests to ensure activation/prune rejects operators blacklisted via operator mapping.
contracts/src/interfaces/IContentBlacklistOriginView.sol Expands view interface to include isOperatorBlacklisted.
contracts/src/interfaces/ICapacityBondSlashEscrow.sol Adds pausedTotal() + creditPauseTime() to support combined pause accounting.
contracts/src/interfaces/IFeeRouter.sol Updates NatSpec to reflect 3-bucket 60/30/10 split.
Comments suppressed due to low confidence (2)

contracts/src/FeeRouter.sol:262

  • endEpoch + 1 can overflow (e.g. endEpoch == type(uint64).max) and the for (e <= endEpoch; e++) pattern will also overflow/revert on the final increment when endEpoch is max. Even if current callers pass sane epochs, these are public view functions and should be robust against extreme inputs.
        uint64 startEpoch = endEpoch + 1 > n ? endEpoch + 1 - n : 0;
        for (uint64 e = startEpoch; e <= endEpoch; e++) {
            sum += _bytesPerEpoch[operator][e];
        }
    }

contracts/src/FeeRouter.sol:273

  • Same overflow issue here: endEpoch + 1 can overflow and the e++ loop form will overflow/revert when endEpoch == type(uint64).max. Using a subtraction-based start epoch and a break-terminated loop avoids both problems.
        uint64 startEpoch = endEpoch + 1 > n ? endEpoch + 1 - n : 0;
        for (uint64 e = startEpoch; e <= endEpoch; e++) {
            sum += _totalBytesPerEpoch[e];
        }
    }

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces several security, robustness, and architectural improvements across multiple contracts. Key changes include updating the BuybackBurner to enforce non-zero slippage limits, bound spend amounts, and allow governance to rescue stranded USDC. The CapacityBond and SlashAppeal contracts now use a unified pause-time accumulator to prevent pause intervals from consuming appeal windows, and a governance escape hatch was added to resolve stuck appeals. In ContentBlacklist, the regional concurrent appeal cap was moved to only count fast-tracked appeals, and re-adding a hash with an active appeal is now blocked. FeeRouter now clamps query windows to prevent unbounded loops, while OriginAssignment checks both origin and operator blacklist mappings. Finally, PaymentChannel was updated to measure actual received deposits to handle fee-on-transfer behavior and reset router allowances to zero after routing. No review comments were provided, so there is no additional feedback.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

@thiras
thiras merged commit a3bfb70 into main Jun 1, 2026
20 checks passed
@thiras
thiras deleted the security/fix-audit-findings branch June 1, 2026 23:26
thiras added a commit that referenced this pull request Jun 10, 2026
* fix: close out remaining LOW review follow-ups (#845 #864)

Resolves the five still-open `[ ]` items across the two 2026-06
full-repository review umbrellas; all prior items shipped in #867/#868.

node:
- dht: cap per-connection served streams (MAX_DHT_REQUESTS_PER_CONN=256)
  and connection age (MAX_DHT_CONN_AGE=5m) so a peer staying under the
  per-stream rate limit can no longer pin its dispatch permit forever,
  mirroring handlers::client's hardcoded-constant precedent (#845).
- reputation_indexer: bound the settled_seen dedup set with a companion
  FIFO (MAX_SETTLED_SEEN=65536), evicting the longest-settled ids first,
  mirroring the existing pending_settled bound — it no longer grows for
  the whole process lifetime (#864).

cli:
- bundle: consult the --exclude globset via filter_entry before
  canonicalize, pruning recursively-excluded directories. An escaping
  symlink inside an excluded subtree is no longer resolved and can't trip
  the escape bail!; a one-level tmp/* still keeps deeper tmp/sub/y via a
  sentinel-child recursion probe (#845).
- config: add [gossip]/[security]/[dht.rate_limit]/[receipts] template
  blocks plus the missing network/blockchain/cache/payment/observability
  knobs to DEFAULT_CONFIG, and surface each section's kill-switch /
  rate-limit knobs in the validate summary; add a template round-trip
  parse test (#864).

contracts (docs-only):
- IFeeRouter: NatSpec now marks the 60/30/10 split as the default,
  governance-mutable within per-bucket bounds via setShares — the drift
  flagged in #845 was in fact still present (not resolved by #777).

Verification: cargo fmt/clippy --all-targets clean; cargo nextest run
1694/1694 pass; forge fmt --check + FOUNDRY_PROFILE=ci forge build clean.

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>

* fix(cli): use working example values for settlement_auto_* template knobs

The DEFAULT_CONFIG template showed `settlement_auto_threshold_micro_usdc = 0`
and `settlement_auto_by_voucher_nonce_span = 0`, but the resolver rejects
`Some(0)` for both ("must be > 0 when set", mod.rs:1065-1080) — these fields
disable via omission (None / commented-out), not via 0. Uncommenting the line
verbatim would fail `config validate` / node startup. Show realistic positive
example values (50 USDC / 1000 nonces) and reword the annotation to "leave
unset/commented to disable", matching how the other commented knobs in the
template carry working values.

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>

* fix: address multi-agent review findings (#845 #864)

reputation_indexer:
- Correct the MAX_SETTLED_SEEN comment: a re-delivered settlement for an
  evicted channel re-credits the provider (resolved from the never-removed
  on-chain CapacityBond binding), it is NOT a no-op as previously claimed.
  Document it as a bounded, astronomically-unlikely double-count and explain
  why eviction stays at debug! (routine once saturated). Cross-reference from
  the mark_settled_seen doc; harmonize the #867/#868 citation to #864.

node/dht:
- The cap/age break dropped the peer's further requests silently. Now log
  (debug) which bound tripped and conn.close() with APP_ERR_RATE_LIMITED,
  mirroring close_stream_with_rate_limit and the client permit-exhaustion
  close, so the peer gets a reason and the close is observable.
- Extract the accept-budget gate into accept_budget_reached() so the unit
  test exercises the real predicate instead of a re-implementation, and
  cover the previously-untested age branch. Correct the false comment that
  claimed tests/dht_loopback.rs exercises the cap end-to-end (it does not —
  it only proves multi-stream serving); state honestly what is covered.

cli/bundle:
- Add a test for an excluded directory that is itself an escaping symlink
  (tmp/** where tmp -> external dir): confirms the subtree is pruned before
  canonicalize and does not trip the escape bail!.

Verification: cargo fmt/clippy --all-targets clean; decdn-node + decdn-cli
753 tests pass.

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>

---------

Co-authored-by: Claude Opus 4.8 (1M context) <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants