CowSettlementAssertion
Inherits: CowSettlementHelpers
Title: CowSettlementAssertion
Author: Phylax Systems
Guards watched Settlement buffers against outflows not explained by GPv2 trade volume or an authorized DAO sweep.
A signed order may legitimately pay any receiver, and Trade events do not expose that receiver. The assertion therefore makes no receiver-level claim about normal settlement volume. The two allowances are kept disjoint by destination: transfers to the sweep Safe are always an authorized destination, while outflow to anyone else must be covered by the token’s reported trade volume. Because a Safe-bound transfer may itself be an order payment, a transaction that pays both destinations more than trade volume explains cannot be attributed and is explicitly quarantined rather than credited both allowances. Gross accounting catches standing-allowance drains even when same-transaction prefunding hides the endpoint delta.
Functions
constructor
constructor(
address settlement_,
address sweepRecipient_,
address[] memory bufferTokens_,
uint256 bufferToleranceBps_
) CowSettlementHelpers(settlement_, sweepRecipient_, bufferTokens_, bufferToleranceBps_);
triggers
Registers the per-token outflow reconciliation at transaction end and on token changes.
function triggers() external view override;
assertBufferConserved
Watched-token outflow must be explained by same-token trade volume or a DAO sweep.
function assertBufferConserved() external view;